[iptables] - fixed update from RHEL-6 to RHEL-7 (RHBZ#1043901)

Thomas Woerner twoerner at fedoraproject.org
Wed Jan 15 12:22:37 UTC 2014


commit b16a3888f162d1ae07dbf1332d82e09149f0b3cd
Author: Thomas Woerner <twoerner at redhat.com>
Date:   Wed Jan 15 13:22:39 2014 +0100

    - fixed update from RHEL-6 to RHEL-7 (RHBZ#1043901)

 iptables.spec |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/iptables.spec b/iptables.spec
index 060b1f2..31bbe90 100644
--- a/iptables.spec
+++ b/iptables.spec
@@ -125,6 +125,16 @@ install -c -m 755 %{SOURCE4} %{buildroot}/%{legacy_actions}/iptables/save
 sed -e 's;iptables.init;ip6tables.init;g' -e 's;IPTABLES;IP6TABLES;g' < %{buildroot}/%{legacy_actions}/iptables/save > ip6tabes.save-legacy
 install -c -m 755 ip6tabes.save-legacy %{buildroot}/%{legacy_actions}/ip6tables/save
 
+%if 0%{?rhel}
+%pre
+for p in %{_sysconfdir}/alternatives/{iptables,ip6tables}.*; do
+    if [ -h "$p" ]; then
+        ipt=$(readlink "$p")
+        echo "Removing alternatives for ${p##*/} with path $ipt"
+        %{_sbindir}/alternatives --remove "${p##*/}" "$ipt"
+    fi
+done
+%endif
 
 %post -p /sbin/ldconfig
 
@@ -193,6 +203,9 @@ install -c -m 755 ip6tabes.save-legacy %{buildroot}/%{legacy_actions}/ip6tables/
 
 
 %changelog
+* Wed Jan 15 2014 Thomas Woerner <twoerner at redhat.com> 1.4.21-6
+- fixed update from RHEL-6 to RHEL-7 (RHBZ#1043901)
+
 * Tue Jan 14 2014 Jiri Popelka <jpopelka at redhat.com> - 1.4.21-5
 - chmod /etc/sysconfig/ip[6]tables 755 -> 600
 


More information about the scm-commits mailing list