diff options
author | psykose <alice@ayaya.dev> | 2023-05-12 13:47:01 +0000 |
---|---|---|
committer | psykose <alice@ayaya.dev> | 2023-05-12 19:39:59 +0200 |
commit | f87a191922955bcf5c5f3fc66a425263a4588d48 (patch) | |
tree | ed705ecb41bdaf64c807270fd340972be8e7efbb /main/iptables/APKBUILD | |
parent | fe3e9790655f139b8c63b021ef6f1bb23f31502c (diff) | |
download | aports-f87a191922955bcf5c5f3fc66a425263a4588d48.zip |
main/iptables: make default iptables* links to nft variant
closes #14058
Diffstat (limited to 'main/iptables/APKBUILD')
-rw-r--r-- | main/iptables/APKBUILD | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/main/iptables/APKBUILD b/main/iptables/APKBUILD index 311ef8e582a..ff91747cdb6 100644 --- a/main/iptables/APKBUILD +++ b/main/iptables/APKBUILD @@ -1,16 +1,16 @@ # Maintainer: Natanael Copa <ncopa@alpinelinux.org> pkgname=iptables pkgver=1.8.9 -pkgrel=2 +pkgrel=3 pkgdesc="Linux kernel firewall, NAT and packet mangling tools" url="https://www.netfilter.org/projects/iptables/index.html" arch="all" license="GPL-2.0-or-later" depends_dev="linux-headers" makedepends="$depends_dev libnftnl-dev bison flex autoconf automake" -subpackages="ip6tables $pkgname-doc $pkgname-dev $pkgname-openrc ip6tables-openrc:ip6tables_openrc" -provides="ebtables=$pkgver-r$pkgrel" # for backards compat -replaces="ebtables" +subpackages="$pkgname-doc $pkgname-dev $pkgname-openrc" +provides="ip6tables=$pkgver-r$pkgrel ebtables=$pkgver-r$pkgrel" # for backards compat +replaces="ip6tables ebtables" source="https://www.netfilter.org/projects/iptables/files/iptables-$pkgver.tar.xz format-security.patch use-sh-iptables-apply.patch @@ -47,6 +47,7 @@ package() { mkdir -p "$pkgdir"/usr/include/libiptc \ "$pkgdir"/usr/lib \ "$pkgdir"/var/lib/iptables \ + "$pkgdir"/var/lib/ip6tables \ "$pkgdir"/etc/iptables install -m644 include/iptables.h include/ip6tables.h \ @@ -55,27 +56,23 @@ package() { install -D -m755 "$srcdir"/iptables.initd "$pkgdir"/etc/init.d/iptables install -D -m644 "$srcdir"/iptables.confd "$pkgdir"/etc/conf.d/iptables + install -D -m755 "$srcdir"/iptables.initd "$pkgdir"/etc/init.d/ip6tables + install -D -m644 "$srcdir"/ip6tables.confd "$pkgdir"/etc/conf.d/ip6tables install -D -m755 "$srcdir"/ebtables.initd "$pkgdir"/etc/init.d/ebtables install -D -m644 "$srcdir"/ebtables.confd "$pkgdir"/etc/conf.d/ebtables -} - -ip6tables() { - mkdir -p "$subpkgdir" - cd "$subpkgdir" - mkdir -p sbin \ - var/lib/ip6tables \ - usr/lib/xtables - - mv "$pkgdir"/sbin/ip6* sbin/ - mv "$pkgdir"/usr/lib/xtables/libip6* usr/lib/xtables/ + ln -sfv xtables-nft-multi "$pkgdir"/sbin/iptables + ln -sfv xtables-nft-multi "$pkgdir"/sbin/iptables-save + ln -sfv xtables-nft-multi "$pkgdir"/sbin/iptables-restore + ln -sfv xtables-nft-multi "$pkgdir"/sbin/ip6tables + ln -sfv xtables-nft-multi "$pkgdir"/sbin/ip6tables-save + ln -sfv xtables-nft-multi "$pkgdir"/sbin/ip6tables-restore } -ip6tables_openrc() { +openrc() { default_openrc - - install -D -m755 "$srcdir"/iptables.initd "$subpkgdir"/etc/init.d/ip6tables - install -D -m644 "$srcdir"/ip6tables.confd "$subpkgdir"/etc/conf.d/ip6tables + provides="ip6tables-openrc=$pkgver-r$pkgrel" + replaces="ip6tables-openrc" } sha512sums=" |