PREUN
/bin/sh
if [ "$1" = "0" ]; then
[ ! -f /etc/apache/conf.d/??_mod_php4.conf ] || {
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache restart 1>&2 || :;
fi
fi };[ ! -f /etc/httpd/conf.d/??_mod_php4.conf ] || {
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd restart 1>&2 || :;
fi
fi };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
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/php-fcgi ] && . /etc/sysconfig/php-fcgi
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/php-fcgi ]; then
/sbin/service php-fcgi restart 1>&2 || :;
fi
fi }; fi
fi
fi
POSTIN
/bin/sh
# let /usr/lib/Zend/etc point to php's config dir. php which installed first wins.
# not sure how critical is existence of this etc link at all.
if [ ! -L /usr/lib64/Zend/etc ]; then
ln -snf /etc/php4 /usr/lib64/Zend/etc
fi
[ ! -f /etc/apache/conf.d/??_mod_php4.conf ] || {
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache restart 1>&2 || :;
fi
fi };[ ! -f /etc/httpd/conf.d/??_mod_php4.conf ] || {
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd restart 1>&2 || :;
fi
fi };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
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/php-fcgi ] && . /etc/sysconfig/php-fcgi
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/php-fcgi ]; then
/sbin/service php-fcgi restart 1>&2 || :;
fi
fi }; fi
fi
Triggers
ZendOptimizer <
2.5.10a-0.20
/bin/sh
if [ -f /etc/php4/php.ini ]; then
cp -f /etc/php4/conf.d/ZendOptimizer.ini{,.rpmnew}
sed -ne '/^\(zend_\|\[Zend\]\)/{/^zend_extension\(_manager\.optimizer\)\?\(_ts\)\?=/d;p}' /etc/php4/php.ini > /etc/php4/conf.d/ZendOptimizer.ini
cp -f /etc/php4/php.ini{,.rpmsave}
sed -i -e '/^\(zend_\|\[Zend\]\)/d' /etc/php4/php.ini
fi