wok-6.x annotate php-pear/receipt @ rev 18134

poptop: add plugin
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Jun 13 17:27:08 2015 +0200 (2015-06-13)
parents 76c1f14d1820
children 9e01bc6321ea
rev   line source
pascal@1779 1 # SliTaz package receipt.
pascal@1779 2
pascal@1779 3 PACKAGE="php-pear"
erjo@16733 4 VERSION="5.5.13"
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@15198 8 LICENSE="BSD"
pascal@1779 9 WEB_SITE="http://www.php.net/"
pascal@1779 10 WANTED="php"
pascal@1779 11
pascal@15198 12 DEPENDS="php-cli"
pascal@15198 13
pascal@1779 14 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@1779 15 genpkg_rules()
pascal@1779 16 {
pascal@1779 17 mkdir -p $fs/usr/share $fs/usr/bin $fs/etc
slaxemulator@14614 18 cp -a $install/usr/share/php $fs/usr/share
slaxemulator@14614 19 cp -a $install/etc/pear.conf $fs/etc
slaxemulator@14614 20 cp -a $install/usr/bin/pe* $fs/usr/bin
pascal@1779 21 }
pascal@1781 22
pascal@1781 23 # Pre and post install commands for Tazpkg.
pascal@1805 24 pre_install()
pascal@1805 25 {
pascal@1805 26 while read daemon file; do
pascal@1805 27 if [ -z "$1" -a -f "/var/run/$file" ]; then
pascal@1805 28 /etc/init.d/$daemon stop
pascal@1805 29 fi
pascal@1805 30 done <<EOT
pascal@1805 31 apache apache/httpd.pid
pascal@1805 32 lighttpd lighttpd.pid
pascal@1805 33 EOT
pascal@1805 34 }
pascal@1805 35
pascal@1781 36 post_install()
pascal@1781 37 {
pascal@1781 38 grep ^include_path $1/etc/php.ini
pascal@1781 39 sed -i 's|/php/includes"|/php/includes"\ninclude_path = ".:/usr/share/php"|' $1/etc/php.ini
pascal@1782 40 # Restart Web server.
pascal@1805 41 while read daemon file; do
pascal@1805 42 [ -z "$1" ] || continue
pascal@1805 43 if [ -f "/var/run/$file" ]; then
pascal@1805 44 /etc/init.d/$daemon stop
pascal@1805 45 sleep 2
pascal@1805 46 fi
pascal@1782 47 if [ -f /etc/init.d/$daemon ]; then
pascal@1782 48 /etc/init.d/$daemon start
pascal@1782 49 fi
pascal@1805 50 done <<EOT
pascal@1805 51 apache apache/httpd.pid
pascal@1805 52 lighttpd lighttpd.pid
pascal@1805 53 EOT
pascal@1781 54 }