Author: glen                         Date: Sun Nov 20 21:54:14 2005 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- less if statements

---- Files affected:
SOURCES:
   rpm.macros (1.265 -> 1.266) 

---- Diffs:

================================================================
Index: SOURCES/rpm.macros
diff -u SOURCES/rpm.macros:1.265 SOURCES/rpm.macros:1.266
--- SOURCES/rpm.macros:1.265    Sun Nov 20 20:41:57 2005
+++ SOURCES/rpm.macros  Sun Nov 20 22:54:09 2005
@@ -722,12 +722,9 @@
 if [ "$1" = "1" ] && [ "$2" = "1" ]; then\
        /usr/sbin/webapp register %1 %2\
 fi\
-# reload webserver if the config symlink is there\
-if [ -L /etc/%1/webapps.d/%2.conf ]; then\
-       # additionally don't reload if target package (the webserver) is 
upgraded, as webserver is restarted anyway in %post \
-       if [ "$2" != "2" ] && [ -f /var/lock/subsys/%1 ]; then\
-               /etc/rc.d/init.d/%1 reload 1>&2\
-       fi\
+# reload webserver if the config symlink is there and skip reload if webserver 
is upgraded\
+if [ -L /etc/%1/webapps.d/%2.conf ] && [ "$2" -lt "2" ] && [ -f 
/var/lock/subsys/%1 ]; then\
+       /etc/rc.d/init.d/%1 reload 1>&2\
 fi\
 %{nil}
 
@@ -737,17 +734,13 @@
 %webapp_unregister() \
 %{?debug:set -x; echo "webapp_unregister: %{name}-%{version}-%{release}: 
1:[$1]; 2:[$2]"} \
 # remove link if either of the packages are gone \
-if [ "$1" = "0" ] || [ "$2" = "0" ]; then \
-       if [ -L /etc/%1/webapps.d/%2.conf ]; then \
-               rm -f /etc/%1/webapps.d/%2.conf \
-               if [ -f /var/lock/subsys/%1 ]; then \
-                       /etc/rc.d/init.d/%1 reload 1>&2 \
-               fi \
+if [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/%1/webapps.d/%2.conf ]; then \
+       rm -f /etc/%1/webapps.d/%2.conf \
+       if [ -f /var/lock/subsys/%1 ]; then \
+               /etc/rc.d/init.d/%1 reload 1>&2 \
        fi \
 fi \
 %{nil}
-
-
 
 # see browser-plugins.spec / template-browser-plugin.spec
 # written by [EMAIL PROTECTED]
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SOURCES/rpm.macros?r1=1.265&r2=1.266&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to