aboutsummaryrefslogtreecommitdiffstats
path: root/community/miniupnpd/APKBUILD
blob: 360458258ea75e41b0524a2a5c60134c15ce6d12 (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.2.3
pkgrel=1
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="
56b1e93e9576fa412202e1940fcd8b7af57584714c15017bbcec1aa4fa7bba7a6fa5d1136048100d7cce3222f31b38837de1eae344b533164314c858cdf08ef9  miniupnpd-2.2.3.tar.gz
3619d66b5d27369e9ae368f189fc4f4e25a803b460a954f47fd749195755bda8e828fbaa4e04ffc980aa72078f790d41a313c2ab7d0de7d4c284251a577b7a90  miniupnpd.initd
"