aboutsummaryrefslogtreecommitdiffstats
path: root/main/ser2net/APKBUILD
blob: af7bae4789375c4fe65a221a06a23b8a728d1445 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=ser2net
pkgver=2.10.0
pkgrel=0
pkgdesc="A proxy that allows telnet/tcp connections to be made to serial ports"
url="http://sourceforge.net/projects/ser2net"
arch="all"
license="GPL"
depends=""
depends_dev=""
makedepends="$depends_dev"
install=""
subpackages="$pkgname-doc"
source="http://heanet.dl.sourceforge.net/project/ser2net/ser2net/ser2net-$pkgver.tar.gz
	TIOCSRS485.patch
	${pkgname}.confd
	${pkgname}.initd"

_builddir="$srcdir"/ser2net-$pkgver
prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--localstatedir=/var \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
        install -D -m755 "$srcdir"/ser2net.initd \
		"$pkgdir"/etc/init.d/ser2net
	install -D -m644 "$srcdir"/ser2net.confd \
		"$pkgdir"/etc/conf.d/ser2net
	install -D -m644 ser2net.conf \
		"$pkgdir"/etc/ser2net.conf
	rm -f "$pkgdir"/usr/lib/*.la
}

md5sums="cd937041144de83d41d811521e72158c  ser2net-2.10.0.tar.gz
cfeb58eb6b059e5ff09357062ad0699d  TIOCSRS485.patch
100fc9cc68a766afde182d14a26bfec0  ser2net.confd
d57ce51bc3d70cf66d3837bdc0a7df7c  ser2net.initd"
sha256sums="98f6193225338e25f35302fef5e1f16688693ed43e7b3c3e9e09187eb54547ac  ser2net-2.10.0.tar.gz
444eea3752a3209ccbba87cf2374843011595ebf495b7e4e807e39e0d08412a7  TIOCSRS485.patch
3058368970e77b8b7fcf6fca9f3530b683d9e9c27c431531f8566dde01dab849  ser2net.confd
6993e7965e17d0498b50ac09be772da436447bb7ed07520818a70b82b3a6ef80  ser2net.initd"
sha512sums="dd3e37619b10d8bf20d738e90c253bc2d109e0a57ee9f3a8b2a85a69399afa5a8459a4602b2856f0b655427023a36c78330851bf7f8d8da0f28d1fe22c1d5e10  ser2net-2.10.0.tar.gz
c545b47f49857f2a83b7250c0f3d80787e29cc2f4ca2d9b579df9f41f50ba60da26f53ec75659eede712b182cac616e438af60fd6d11c8c4acc006f7827ee9e6  TIOCSRS485.patch
15054f7aa604f93bd5a54c2bb96c9a3168905be5ace50bcd2ebeeaf9dc9ae19426388e6118e9e4850125349090ee29542c24487e64c349593a76366be4a5e501  ser2net.confd
a1dac24c0a379b8deaef66a3e53717c59a11c94e10048ed810d2c673d79cd382671d19364b33de9dd676d19c0275dd22d66e102be0c2e644d959654fd5dbeeea  ser2net.initd"