SOURCES: rpm.macros - restart also php-fcgi in %php*_webserver_res...

glen glen at pld-linux.org
Thu Dec 14 09:30:13 CET 2006


Author: glen                         Date: Thu Dec 14 08:30:13 2006 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- restart also php-fcgi in %php*_webserver_restart if it is configured for that version of php

---- Files affected:
SOURCES:
   rpm.macros (1.342 -> 1.343) 

---- Diffs:

================================================================
Index: SOURCES/rpm.macros
diff -u SOURCES/rpm.macros:1.342 SOURCES/rpm.macros:1.343
--- SOURCES/rpm.macros:1.342	Thu Dec 14 09:18:00 2006
+++ SOURCES/rpm.macros	Thu Dec 14 09:30:07 2006
@@ -581,12 +581,24 @@
 %php_webserver_restart \
 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart \
 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart \
+if [ -f /etc/rc.d/init.d/php-fcgi ]; then \
+	PHP_FCGI_BINARY=; . /etc/sysconfig/php-fcgi 2>/dev/null \
+	if [[ ${PHP_FCGI_BINARY:-php.fcgi} = *php.fcgi* ]]; then \
+		%service -q php-fcgi restart \
+	fi \
+fi \
 %{nil}
 
 # for using php post scripts. for PHP >= 4.0 && PHP < 5.0
 %php4_webserver_restart \
 [ ! -f /etc/apache/conf.d/??_mod_php4.conf ] || %service -q apache restart \
 [ ! -f /etc/httpd/httpd.conf/??_mod_php4.conf ] || %service -q httpd restart \
+if [ -f /etc/rc.d/init.d/php-fcgi ]; then \
+	PHP_FCGI_BINARY=; . /etc/sysconfig/php-fcgi 2>/dev/null \
+	if [[ ${PHP_FCGI_BINARY:-php.fcgi} = *php4.fcgi* ]]; then \
+		%service -q php-fcgi restart \
+	fi \
+fi \
 %{nil}
 
 # Python specific macro definitions.
================================================================

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



More information about the pld-cvs-commit mailing list