aboutsummaryrefslogtreecommitdiffstats
path: root/community/miniupnpd/APKBUILD
blob: ad8e2a9320fd598f3d9bceab01eb72aeb5d92862 (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
# Contributor: Carlo Landmeter <clandmeter@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=miniupnpd
pkgver=2.3.0
pkgrel=0
pkgdesc="Lightweight UPnP IGD daemon"
url="http://miniupnp.free.fr"
arch="all"
license="BSD-3-Clause"
install="$pkgname.post-install"
depends="uuidgen"
makedepends="bsd-compat-headers iptables-dev libnfnetlink-dev openssl1.1-compat-dev"
checkdepends="util-linux-dev"
subpackages="$pkgname-doc $pkgname-openrc
	$pkgname-iptables:_fwscripts:noarch
	$pkgname-ip6tables:_fwscripts:noarch
	"
source="http://miniupnp.free.fr/files/miniupnpd-$pkgver.tar.gz
	$pkgname.initd
"

# secfixes:
#   2.2.2-r0:
#     - CVE-2019-12107
#     - CVE-2019-12108
#     - CVE-2019-12109
#     - CVE-2019-12110
#     - CVE-2019-12111

build() {
	./configure \
		--vendorcfg \
		--leasefile \
		--ipv6 \
		--igd2
	make ISGITREPO=""
}

check() {
	make check ISGITREPO=""
}

package() {
	make PREFIX="$pkgdir/" ISGITREPO="" install
	install -m755 -D "$srcdir"/$pkgname.initd \
		"$pkgdir"/etc/init.d/$pkgname
}

_fwscripts() {
	depends=
	local _tables=${subpkgname#$pkgname-}
	pkgdesc="$_tables scripts for $pkgname"
	install_if="$pkgname=$pkgver-r$pkgrel $_tables"
	amove	/etc/miniupnpd/${_tables}_init.sh \
		/etc/miniupnpd/${_tables}_removeall.sh
}

sha512sums="
437a4b101bcadd9feb3845d37402c253a0a2114463fd8c5930859c7eae0ffaf7714ef7c9d387be2339c584e2f106fafa008a4364ff347b6640153c9a09919b0a  miniupnpd-2.3.0.tar.gz
3619d66b5d27369e9ae368f189fc4f4e25a803b460a954f47fd749195755bda8e828fbaa4e04ffc980aa72078f790d41a313c2ab7d0de7d4c284251a577b7a90  miniupnpd.initd
"