wok-stable annotate php-pear/receipt @ rev 6446

Up: enca, enca-dev to 1.13.
author Christopher Rogers <slaxemulator@gmail.com>
date Tue Sep 28 13:40:47 2010 +0000 (2010-09-28)
parents cdb7f539e116
children 11b005eb0d03
rev   line source
pascal@1779 1 # SliTaz package receipt.
pascal@1779 2
pascal@1779 3 PACKAGE="php-pear"
pankso@4427 4 VERSION="5.2.11"
pascal@1779 5 CATEGORY="development"
pascal@1779 6 SHORT_DESC="PHP web programming language pear libs."
pascal@1779 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@1779 8 DEPENDS="php"
pascal@1779 9 WEB_SITE="http://www.php.net/"
pascal@1779 10 WANTED="php"
pascal@1779 11
pascal@1779 12 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@1779 13 genpkg_rules()
pascal@1779 14 {
pascal@1779 15 mkdir -p $fs/usr/share $fs/usr/bin $fs/etc
pascal@1779 16 cp -a $_pkg/usr/share/php $fs/usr/share
pascal@1779 17 cp $_pkg/etc/pear.conf $fs/etc
pascal@1779 18 cp $_pkg/usr/bin/pe* $fs/usr/bin
pascal@1779 19 }
pascal@1781 20
pascal@1781 21 # Pre and post install commands for Tazpkg.
pascal@1805 22 pre_install()
pascal@1805 23 {
pascal@1805 24 while read daemon file; do
pascal@1805 25 if [ -z "$1" -a -f "/var/run/$file" ]; then
pascal@1805 26 /etc/init.d/$daemon stop
pascal@1805 27 fi
pascal@1805 28 done <<EOT
pascal@1805 29 apache apache/httpd.pid
pascal@1805 30 lighttpd lighttpd.pid
pascal@1805 31 EOT
pascal@1805 32 }
pascal@1805 33
pascal@1781 34 post_install()
pascal@1781 35 {
pascal@1781 36 grep ^include_path $1/etc/php.ini
pascal@1781 37 sed -i 's|/php/includes"|/php/includes"\ninclude_path = ".:/usr/share/php"|' $1/etc/php.ini
pascal@1782 38 # Restart Web server.
pascal@1805 39 while read daemon file; do
pascal@1805 40 [ -z "$1" ] || continue
pascal@1805 41 if [ -f "/var/run/$file" ]; then
pascal@1805 42 /etc/init.d/$daemon stop
pascal@1805 43 sleep 2
pascal@1805 44 fi
pascal@1782 45 if [ -f /etc/init.d/$daemon ]; then
pascal@1782 46 /etc/init.d/$daemon start
pascal@1782 47 fi
pascal@1805 48 done <<EOT
pascal@1805 49 apache apache/httpd.pid
pascal@1805 50 lighttpd lighttpd.pid
pascal@1805 51 EOT
pascal@1781 52 }