summaryrefslogtreecommitdiff
path: root/user/wireguard-tools/APKBUILD
blob: 37aeb1ab767023e55f668e6e2f752fe28d2ccbeb (plain) (blame)
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
# Contributor: Luis Ressel <aranea@aixah.de>
# Maintainer: Luis Ressel <aranea@aixah.de>
pkgname=wireguard-tools
pkgver=1.0.20200102
pkgrel=0
pkgdesc="Userland tools for the WireGuard VPN"
url="https://www.wireguard.com/"
arch="all"
options="!check" # no test suite
license="GPL-2.0-only"
depends="bash iproute2"
makedepends="libmnl-dev"
subpackages="$pkgname-bash-completion:bashcomp:noarch $pkgname-doc"
source="https://git.zx2c4.com/$pkgname/snapshot/$pkgname-$pkgver.tar.xz"
builddir="$srcdir/$pkgname-$pkgver"

build() {
	cd "$builddir"
	make RUNSTATEDIR=/run -C src
}

package() {
	cd "$builddir"
	make WITH_BASHCOMPLETION=yes WITH_WGQUICK=yes DESTDIR="$pkgdir" -C src install
}

bashcomp() {
	depends="$pkgname"
	pkgdesc="$pkgdesc (Bash completion)"

	mkdir -p "$subpkgdir/usr/share"
	mv "$pkgdir/usr/share/bash-completion" "$subpkgdir/usr/share/"
}

sha512sums="a4275eefc55b2a7ed3935a46a2098f9b0acdfaf0e1ed33ca42b51a186b388b53425ded5887e2cfc5be2802d6a453b8ebbf0294800ec1307a2dc21f46bd040da6  wireguard-tools-1.0.20200102.tar.xz"