Fiddle with RPM upgrade

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@5198 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-01-04 13:35:03 +00:00
parent 61c79ea951
commit 869e8a2fd6

View File

@ -43,8 +43,8 @@ rm -rf $RPM_BUILD_ROOT
%pre
if [ $1 -eq 2 -a -f /etc/shorewall-lite/shorewall.conf ]; then
mv -f /etc/shorewall-lite/shorewall.conf /etc/shorewall-lite/shorewall-lite.conf
if [ -f /etc/shorewall-lite/shorewall.conf ]; then
cp -fa /etc/shorewall-lite/shorewall.conf /etc/shorewall-lite/shorewall.conf.rpmsave
fi
%post
@ -55,6 +55,9 @@ if [ $1 -eq 1 ]; then
elif [ -x /sbin/chkconfig ]; then
/sbin/chkconfig --add shorewall-lite;
fi
elif [ -f /etc/shorewall-lite/shorewall.conf.rpmsave ]; then
mv -f /etc/shorewall-lite/shorewall-lite.conf /etc/shorewall-lite/shorewall-lite.conf.rpmnew
mv -f /etc/shorewall-lite/shorewall.conf.rpmsave /etc/shorewall/shorewall-lite.conf
fi
%preun