wok-next annotate php-pear/receipt @ rev 15142
bmpanel2: typo
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Aug 15 11:41:58 2013 +0000 (2013-08-15) |
parents | 855f42b596c0 |
children | 78cb1e930abd |
rev | line source |
---|---|
pascal@1779 | 1 # SliTaz package receipt. |
pascal@1779 | 2 |
pascal@1779 | 3 PACKAGE="php-pear" |
slaxemulator@14614 | 4 VERSION="5.4.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" |
erjo@8352 | 8 DEPENDS="php-cli" |
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 |
slaxemulator@14614 | 16 cp -a $install/usr/share/php $fs/usr/share |
slaxemulator@14614 | 17 cp -a $install/etc/pear.conf $fs/etc |
slaxemulator@14614 | 18 cp -a $install/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 } |