aboutsummaryrefslogtreecommitdiffstats
path: root/testing/strongswan/APKBUILD
blob: b90a3e2185dde4f37cbfaf800011abccea8ee0ed (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
69
70
71
72
73
74
# Contributor: Jesse Young <jlyo@jlyo.org>
# Maintainer:
pkgname=strongswan
pkgver=4.6.1
pkgrel=0
pkgdesc="IPsec-based VPN solution focused on security and ease of use, supporting IKEv1/IKEv2 and MOBIKE"
url="http://www.strongswan.org/"
arch="all"
license="GPL-2 RSA-MD5 RSA-PKCS11 DES"
depends="iproute2 openssl"
depends_dev="sqlite-dev openssl-dev curl-dev gmp-dev"
makedepends="$depends_dev"
install=""
subpackages="$pkgname-doc"
source="http://download.strongswan.org/$pkgname-$pkgver.tar.bz2 adns.patch strongswan.initd"

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

build() {
	cd "$_builddir"
	 ./configure --prefix=/usr \
		--sysconfdir=/etc \
		--libexecdir=/usr/lib \
		--with-ipsecdir=/usr/lib/strongswan \
		--enable-pluto \
		--enable-sqlite \
		--enable-smartcard \
		--enable-cisco-quirks \
		--enable-openssl \
		--enable-curl \
		--enable-sql \
		--enable-attr-sql \
		--enable-farp \
		--enable-dhcp \
		--enable-eap-sim \
		--enable-eap-sim-file \
		--enable-eap-simaka-pseudonym \
		--enable-eap-simaka-reauth \
		--enable-eap-identity \
		--enable-eap-md5 \
		--disable-eap-gtc \
		--enable-eap-aka \
		--enable-eap-aka-3gpp2 \
		--enable-eap-mschapv2 \
		--enable-eap-radius \
		--enable-ha \
		--disable-mysql \
		--disable-ldap \
		--disable-static \
		--enable-shared || return 1
	make || return 1
}

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

md5sums="85a28a12ed6f286a5bc9117e3a9386bb  strongswan-4.6.1.tar.bz2
8f02d0e582ac9ac60c28e465b626481d  adns.patch
fb9822512d02f521af8812db22a5175e  strongswan.initd"