# Maintainer: Natanael Copa _flavor=${FLAVOR:-grsec} _kpkg=linux-$_flavor _realname=xtables-addons _name=$_realname-$_flavor _kver=3.13.8 _kpkgrel=0 _realver=2.4 _mypkgrel=0 # source the kernel version if [ -f ../linux-$_flavor/APKBUILD ]; then . ../linux-$_flavor/APKBUILD [ "$_kver" != "$pkgver" ] && die "$_name: Please update _kver to $pkgver" [ "$_kpkgrel" != "$pkgrel" ] && die "$_name: Please update _kpkgrel to $pkgrel" fi _kernelver=$_kver-r$_kpkgrel _abi_release=${_kver}-${_kpkgrel}-${_flavor} pkgname=$_name pkgver=$_kver pkgrel=$(($_kpkgrel + $_mypkgrel)) pkgdesc="Iptables extensions kernel modules" url="http://xtables-addons.sourceforge.net/" arch="all" license="GPL" depends="linux-${_flavor}=${_kernelver}" makedepends="linux-${_flavor}-dev=${_kernelver} iptables-dev pkgconfig" install= install_if="linux-$_flavor=$_kernelver $_realname" subpackages= source="http://downloads.sourceforge.net/$_realname/$_realname-$_realver.tar.xz" _builddir="$srcdir/$_realname-$_realver" prepare() { cd "$_builddir" } build() { cd "$_builddir" ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr \ --with-kbuild=/usr/src/linux-headers-${_abi_release} \ || return 1 cd extensions export GCC_SPECS=hardenednopie.specs make CC="${CC:-gcc}" modules || return 1 } package() { cd "$_builddir/extensions" make DESTDIR="$pkgdir" modules_install } md5sums="b2dfe9a37f328d3a3f6fe402e0596a2c xtables-addons-2.4.tar.xz" sha256sums="c765a37ea9e8324832d68fd67fdfc2189db1cb9240f2b048aca6064ba9c13cdb xtables-addons-2.4.tar.xz" sha512sums="650182a9078c2ce9b66a26cc0f6224e1a5fc09bb88a714b44c6d0be9fbb73f83a19ab98d085ac24f22ba564d8614d62507ff71d45c1f305f037734f23a842915 xtables-addons-2.4.tar.xz"