# Contributor: Kaarle Ritvanen # Maintainer: Kaarle Ritvanen pkgname=awall pkgver=1.4.1 pkgrel=0 pkgdesc="Alpine Wall" url="http://git.alpinelinux.org/cgit/awall/" arch="noarch" license="GPL2" replaces="awall-nat" depends="bind-tools ip6tables ipset iptables lua lua-alt-getopt lua-cjson lua-pc lua-posix lua-stringy xtables-addons" subpackages=$pkgname-masquerade triggers="$pkgname.trigger=/usr/share/awall" source="http://dev.alpinelinux.org/archive/awall/awall-$pkgver.tar.xz" _builddir=$srcdir/awall-$pkgver prepare() { cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { return 0 } package() { cd "$_builddir" make "ROOT_DIR=$pkgdir" install } masquerade() { depends=awall cd "$_builddir" for file in lua/5.1/awall/modules/masquerade.lua awall/mandatory/masquerade.json; do local path=usr/share/$file install -d "$subpkgdir/$(dirname $path)" mv "$pkgdir/$path" "$subpkgdir/$path" done } md5sums="0b0868f6963a397dc106690cfc984a85 awall-1.4.1.tar.xz" sha256sums="e3049e3828cb0ece4f0751c384462a101ec902b2606c50db8dcb45cf98d5595c awall-1.4.1.tar.xz" sha512sums="9193859eadf15833afba9e82595ffc7059ec8be9475bb6fbb9a29f87388653d7037b97596fcfeb735c6398f038a88e20859d206efb29476f40fb16a4401950c7 awall-1.4.1.tar.xz"