SHA256
1
0
forked from pool/iptables

merge iptables-default-backend into iptables (else there will be %post errors because iptables-backend-default gets installed before iptables is)

OBS-URL: https://build.opensuse.org/package/show/security:netfilter/iptables?expand=0&rev=108
This commit is contained in:
Jan Engelhardt 2018-09-05 14:38:38 +00:00 committed by Git OBS Bridge
parent eacc4f7ab6
commit e3c936d24b

View File

@ -44,7 +44,6 @@ BuildRequires: pkgconfig(libmnl) >= 1.0
BuildRequires: pkgconfig(libnetfilter_conntrack) >= 1.0.4
BuildRequires: pkgconfig(libnfnetlink) >= 1.0.0
BuildRequires: pkgconfig(libnftnl) >= 1.0.5
Requires: iptables-default-backend
Requires: netcfg >= 11.6
Requires: xtables-plugins = %version-%release
@ -52,21 +51,10 @@ Requires: xtables-plugins = %version-%release
iptables is used to set up, maintain, and inspect the rule tables of
the various Netfilter packet filter engines inside the Linux kernel.
%package backend-legacy
Summary: Metapackage to make x_tables the default backend for iptables
Group: Productivity/Networking/Security
Provides: iptables-default-backend
%description backend-legacy
Installation of this package adds alternatives symlinks (cf.
update-alternatives) that make the iptables and ip6tables commands
point to a program variant that uses the classic kernel interface
provided by ip_tables.ko and ip6_tables.ko.
%package backend-nft
Summary: Metapackage to make nft the default backend for iptables/arptables/ebtables
Group: Productivity/Networking/Security
Provides: iptables-default-backend
Requires: iptables >= 1.8.0
%description backend-nft
Installation of this package adds higher priority alternatives (cf.
@ -181,7 +169,7 @@ mv "$b/%_sbindir/ebtables-save" "$b/%_sbindir/ebtables-nft-save"
%fdupes %buildroot/%_prefix
%endif
%post backend-legacy
%post
update-alternatives \
--install "%_sbindir/iptables" iptables "%_sbindir/xtables-legacy-multi" 1 \
--slave "%_sbindir/iptables-restore" iptables-restore "%_sbindir/xtables-legacy-multi" \
@ -239,8 +227,7 @@ fi
%_sbindir/xtables*
%_mandir/man1/*tables*
%_mandir/man8/*tables*
%files backend-legacy
# backend-legacy (implicit)
%ghost %_sysconfdir/alternatives/iptables
%ghost %_sysconfdir/alternatives/iptables-restore
%ghost %_sysconfdir/alternatives/iptables-save