wok annotate php-dba/receipt @ rev 22874
updated gpgme and gpgme-dev (1.11.1 -> 1.13.1)
author | Hans-G?nter Theisgen |
---|---|
date | Fri Feb 21 17:41:08 2020 +0100 (2020-02-21) |
parents | 84a3b4b621e1 |
children | b10d41313e54 |
rev | line source |
---|---|
pascal@3768 | 1 # SliTaz package receipt. |
pascal@3768 | 2 |
pascal@3768 | 3 PACKAGE="php-dba" |
pascal@22388 | 4 VERSION="7.3.12" |
pascal@3768 | 5 CATEGORY="development" |
pascal@3768 | 6 SHORT_DESC="dba module for PHP web programming language." |
pascal@3768 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@15198 | 8 LICENSE="BSD" |
pascal@21278 | 9 WEB_SITE="https://www.php.net/" |
pascal@3768 | 10 WANTED="php" |
pascal@3768 | 11 |
pascal@3768 | 12 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@3768 | 13 genpkg_rules() |
pascal@3768 | 14 { |
pascal@3768 | 15 mkdir -p $fs/usr/share/php |
slaxemulator@14614 | 16 cp $(find $install | grep dba.so) $fs/usr/share/php/ |
pascal@3768 | 17 } |
pascal@3768 | 18 |
pascal@3768 | 19 # Post and pre install commans to stop |
pascal@3768 | 20 # and restart Web server if needed. |
pascal@3768 | 21 pre_install() |
pascal@3768 | 22 { |
pascal@3768 | 23 while read daemon file; do |
pascal@3768 | 24 if [ -z "$1" -a -f "/var/run/$file" ]; then |
pascal@3768 | 25 /etc/init.d/$daemon stop |
pascal@3768 | 26 fi |
pascal@3768 | 27 done <<EOT |
pascal@3768 | 28 apache apache/httpd.pid |
pascal@3768 | 29 lighttpd lighttpd.pid |
pascal@3768 | 30 EOT |
pascal@3768 | 31 } |
pascal@3768 | 32 |
pascal@3768 | 33 post_install() |
pascal@3768 | 34 { |
pascal@18730 | 35 grep -q ^extension=dba.so "$1/etc/php.ini" || \ |
pascal@22389 | 36 sed -e 's|extension=bz2.so|extension=bz2.so\nextension=dba.so|' -i "$1/etc/php.ini" |
pascal@3768 | 37 # Start Web server. |
pascal@3768 | 38 while read daemon file; do |
pascal@3768 | 39 [ -z "$1" ] || continue |
pascal@3768 | 40 if [ -f "/var/run/$file" ]; then |
pascal@3768 | 41 /etc/init.d/$daemon stop |
pascal@3768 | 42 sleep 2 |
pascal@3768 | 43 fi |
pascal@3768 | 44 if [ -f /etc/init.d/$daemon ]; then |
pascal@3768 | 45 /etc/init.d/$daemon start |
pascal@3768 | 46 fi |
pascal@3768 | 47 done <<EOT |
pascal@3768 | 48 apache apache/httpd.pid |
pascal@3768 | 49 lighttpd lighttpd.pid |
pascal@3768 | 50 EOT |
pascal@3768 | 51 } |
pascal@3768 | 52 |
pascal@3768 | 53 # Pre and post remove commands for Tazpkg. |
pascal@3768 | 54 pre_remove() |
pascal@3768 | 55 { |
pascal@3768 | 56 sed -i '/.*=dba.so.*/d' /etc/php.ini |
pascal@3768 | 57 |
pascal@3768 | 58 # Start Web server. |
pascal@3768 | 59 while read daemon file; do |
slaxemulator@14614 | 60 [ -z "$1" ] || continue |
slaxemulator@14614 | 61 if [ -f "/var/run/$file" ]; then |
pascal@3768 | 62 /etc/init.d/$daemon stop |
pascal@3768 | 63 sleep 2 |
slaxemulator@14614 | 64 fi |
slaxemulator@14614 | 65 if [ -f /etc/init.d/$daemon ]; then |
pascal@3768 | 66 /etc/init.d/$daemon start |
pascal@3768 | 67 fi |
pascal@3768 | 68 done <<EOT |
pascal@3768 | 69 apache apache/httpd.pid |
pascal@3768 | 70 lighttpd lighttpd.pid |
pascal@3768 | 71 EOT |
pascal@3768 | 72 } |