X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?p=php5-apc.git;a=blobdiff_plain;f=debian%2Fphp5-apc.postinst;fp=debian%2Fphp5-apc.postinst;h=1050e8977d3725357837dbb7055cb541b6312b07;hp=0000000000000000000000000000000000000000;hb=5ee5738a895adae39c3e6ad85f158331cc89d522;hpb=d719f07ab3da34dbca04b750335043e3b4ee9e02 diff --git a/debian/php5-apc.postinst b/debian/php5-apc.postinst new file mode 100644 index 0000000..1050e89 --- /dev/null +++ b/debian/php5-apc.postinst @@ -0,0 +1,20 @@ +#!/bin/sh + +set -e + +if [ "$1" != "configure" ]; then + exit 0 +fi + +extension_re='^[[:space:]]*extension[[:space:]]*=[[:space:]]*apc\.so$' +for SAPI in apache apache2 cgi cli; do + ini_file="/etc/php5/$SAPI/php.ini" + if [ -f "$ini_file" ]; then + if grep -q "$extension_re" $ini_file; then + sed -i -e "/$extension_re/d" $ini_file + fi + fi +done + +exit 0 +