]> git.pld-linux.org Git - packages/phpMyAdmin.git/commitdiff
- modified %post, %preun to suit apache/apache2 conf dir and
authorzergin <zergin@pld-linux.org>
Sun, 15 Feb 2004 00:17:20 +0000 (00:17 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
  phpMyAdmin.conf

Changed files:
    phpMyAdmin.spec -> 1.60

phpMyAdmin.spec

index c57ff8e45ef8e35aa5bb7eed04601e5a3d4e5211..e5656988fc119db98e6bab19ce780285cba06e2c 100644 (file)
@@ -88,6 +88,8 @@ rm -rf $RPM_BUILD_ROOT
 %post
 if [ -f /etc/httpd/httpd.conf ] && ! grep -q "^Include.*phpMyAdmin.conf" /etc/httpd/httpd.conf; then
        echo "Include /etc/httpd/phpMyAdmin.conf" >> /etc/httpd/httpd.conf
+elif [ -d /etc/httpd/httpd.conf ]; then
+       mv -f /etc/httpd/%{name}.conf /etc/httpd/httpd.conf/99_%{name}.conf
 fi
 if [ -f /var/lock/subsys/httpd ]; then
        /usr/sbin/apachectl restart 1>&2
@@ -96,11 +98,15 @@ fi
 %preun
 if [ "$1" = "0" ]; then
        umask 027
-       grep -v "^Include.*phpMyAdmin.conf" /etc/httpd/httpd.conf > \
-               etc/httpd/httpd.conf.tmp
-       mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
-       if [ -f /var/lock/subsys/httpd ]; then
-               /usr/sbin/apachectl restart 1>&2
+       if [ -d /etc/httpd/httpd.conf ]; then
+           rm -f /etc/httpd/httpd.conf/99_%{name}.conf
+       else
+               grep -v "^Include.*phpMyAdmin.conf" /etc/httpd/httpd.conf > \
+                       etc/httpd/httpd.conf.tmp
+               mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
+               if [ -f /var/lock/subsys/httpd ]; then
+                   /usr/sbin/apachectl restart 1>&2
+               fi
        fi
 fi
 
This page took 0.03048 seconds and 4 git commands to generate.