wok annotate php/receipt @ rev 22950
updated inotify-tools again (3.14 -> 3.20.2.2)
author | Hans-G?nter Theisgen |
---|---|
date | Fri Feb 28 14:33:03 2020 +0100 (2020-02-28) |
parents | fe96d104d02e |
children | b10d41313e54 |
rev | line source |
---|---|
pankso@18 | 1 # SliTaz package receipt. |
pankso@18 | 2 |
pankso@18 | 3 PACKAGE="php" |
pascal@22388 | 4 VERSION="7.3.12" |
pankso@204 | 5 CATEGORY="development" |
pankso@18 | 6 SHORT_DESC="PHP web programming language." |
pankso@18 | 7 MAINTAINER="pankso@slitaz.org" |
pascal@15198 | 8 LICENSE="BSD" |
pankso@18 | 9 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
pascal@21278 | 10 WEB_SITE="https://www.php.net/" |
pascal@22388 | 11 WGET_URL="https://www.php.net/distributions/$TARBALL" |
pascal@1315 | 12 PROVIDE="php:lighttpd" |
pankso@16079 | 13 #HOST_ARCH="i486 arm" |
pankso@18 | 14 |
pascal@22388 | 15 DEPENDS="php-common lighttpd libzip libxml2 sqlite libssl" |
pascal@22388 | 16 BUILD_DEPENDS="sqlite-dev libxml2-dev libzip-dev libmysqlclient mysql-dev \ |
pankso@9859 | 17 net-snmp-dev postgresql-dev gettext openssl-dev apache-dev apr-util-dev \ |
pankso@9859 | 18 c-client mhash-dev libpng-dev libunixODBC unixODBC-dev openldap-dev \ |
pankso@9859 | 19 libldap apr-dev libmcrypt-dev curl-dev cyrus-sasl-dev perl pkg-config \ |
pascal@22388 | 20 jpeg-dev net-snmp-dev libvpx-dev apache coreutils-conditions sed re2c \ |
pascal@22388 | 21 libtool" |
pankso@9859 | 22 |
pankso@16079 | 23 case "$ARCH" in |
pankso@16079 | 24 i?86) |
pankso@16079 | 25 ARCH_ARGS="\ |
pankso@16079 | 26 --prefix=/usr \ |
pankso@16079 | 27 --sysconfdir=/etc \ |
pankso@16079 | 28 --infodir=/usr/share/info \ |
pankso@16079 | 29 --mandir=/usr/share/man \ |
pankso@16079 | 30 --enable-mbstring \ |
pankso@16079 | 31 --enable-sockets \ |
pankso@16079 | 32 --enable-ftp \ |
pankso@16079 | 33 --enable-zip \ |
pankso@16079 | 34 --enable-calendar \ |
pankso@16079 | 35 --enable-exif \ |
pankso@16079 | 36 --config-cache \ |
pankso@16079 | 37 --enable-dba=shared \ |
pankso@16079 | 38 --with-config-file-path=/etc \ |
pankso@16079 | 39 --with-zlib \ |
pankso@16079 | 40 --with-gettext \ |
pankso@16079 | 41 --with-mysqli=shared \ |
erjo@16732 | 42 --with-mysql-sock=/var/run/mysqld/mysql.sock \ |
pankso@16079 | 43 --with-pdo-sqlite=shared,/usr \ |
pankso@16079 | 44 --with-pgsql=shared,/usr \ |
pankso@16079 | 45 --with-snmp=shared,/usr \ |
pankso@16079 | 46 --enable-soap=shared,/usr \ |
pankso@16079 | 47 --with-ldap=shared \ |
pankso@16079 | 48 --with-imap=shared \ |
pankso@16079 | 49 --with-imap-ssl \ |
pankso@16079 | 50 --with-mhash \ |
pankso@16079 | 51 --with-gd=shared \ |
pankso@16079 | 52 --with-jpeg-dir=/usr \ |
pankso@16079 | 53 --with-png-dir=/usr \ |
pankso@16079 | 54 --with-openssl=shared \ |
pankso@16079 | 55 --with-unixODBC=shared,/usr \ |
pankso@16079 | 56 --with-pear=/usr/share/php \ |
pankso@16079 | 57 --with-pdo-mysql=shared \ |
pankso@16079 | 58 --with-pdo-pgsql=shared \ |
pankso@16079 | 59 --with-curl=shared \ |
pankso@16079 | 60 --with-sqlite3=shared,/usr \ |
pascal@16101 | 61 --enable-maintainer-zts" ;; |
pankso@16079 | 62 arm*) |
pankso@16079 | 63 BUILD_DEPENDS="sqlite-dev libxml2-dev zlib-dev curl-dev" |
pankso@16079 | 64 ARCH_ARGS="\ |
pankso@16079 | 65 --prefix=/usr \ |
pankso@16079 | 66 --sysconfdir=/etc \ |
pankso@16079 | 67 --infodir=/usr/share/info \ |
pankso@16079 | 68 --mandir=/usr/share/man \ |
pankso@16079 | 69 --config-cache \ |
pankso@16079 | 70 --enable-mbstring \ |
pankso@16079 | 71 --enable-sockets \ |
pankso@16079 | 72 --enable-ftp \ |
pankso@16079 | 73 --enable-zip \ |
pankso@16079 | 74 --enable-calendar \ |
pankso@16079 | 75 --enable-exif \ |
pankso@16079 | 76 --enable-dba=shared \ |
pankso@16079 | 77 --enable-sqlite-utf8 \ |
pankso@16079 | 78 --with-mhash \ |
pankso@16079 | 79 --with-sqlite=shared \ |
pankso@16079 | 80 --with-config-file-path=/etc \ |
pankso@16079 | 81 --with-zlib \ |
pankso@16079 | 82 --with-gettext \ |
pankso@16079 | 83 --with-curl=shared \ |
pankso@16079 | 84 --with-openssl=shared \ |
pankso@16079 | 85 --with-jpeg-dir=/usr \ |
pankso@16079 | 86 --with-png-dir=/usr \ |
pankso@16079 | 87 --with-apxs2=/usr/bin/apxs" ;; |
pankso@16079 | 88 esac |
pankso@16079 | 89 |
pankso@18 | 90 # Rules to configure and make the package. |
pankso@18 | 91 compile_rules() |
pankso@18 | 92 { |
pascal@2605 | 93 sed -i 's/pam_start/pam_nostart/' configure |
pascal@16101 | 94 ./configure $ARCH_ARGS $CONFIGURE_ARGS && \ |
slaxemulator@14614 | 95 make $MAKEFLAGS && make -j1 INSTALL_ROOT=$DESTDIR install |
pankso@16079 | 96 ./configure $ARCH_ARGS $CONFIGURE_ARGS --with-apxs2=/usr/bin/apxs && \ |
gokhlayeh@11574 | 97 make $MAKEFLAGS && { |
pankso@9862 | 98 mkdir -p $DESTDIR/etc/apache |
pankso@9862 | 99 cp /etc/apache/httpd.conf $DESTDIR/etc/apache/httpd.conf |
slaxemulator@14614 | 100 make -j1 INSTALL_ROOT=$DESTDIR install |
pascal@1315 | 101 } |
erjo@13052 | 102 # Production config file. |
pankso@10819 | 103 mkdir -p $DESTDIR/etc |
erjo@13052 | 104 cp $src/php.ini-production $DESTDIR/etc/php.ini || exit 1 |
slaxemulator@10549 | 105 sed -e 's|extension_dir = "./"|extension_dir = "/usr/share/php/"|' \ |
slaxemulator@10549 | 106 -i $DESTDIR/etc/php.ini |
pankso@18 | 107 } |
pankso@18 | 108 |
pankso@18 | 109 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@18 | 110 genpkg_rules() |
pankso@18 | 111 { |
pankso@10819 | 112 mkdir -p $fs/usr/bin $fs/usr/share/php |
pankso@18 | 113 cp -a $src/sapi/cgi/php-cgi $fs/usr/bin |
pankso@18 | 114 } |
pankso@18 | 115 |
slaxemulator@14614 | 116 # Post and pre install commands to stop |
slaxemulator@14614 | 117 # and restart Web server if needed. |
pankso@18 | 118 pre_install() |
pankso@18 | 119 { |
slaxemulator@14614 | 120 if [ -z "$1" -a ! -f "/var/run/lighttpd.pid" ]; then |
pankso@18 | 121 /etc/init.d/lighttpd stop |
pankso@18 | 122 fi |
pankso@18 | 123 } |
pankso@9861 | 124 |
pankso@18 | 125 post_install() |
pankso@18 | 126 { |
pascal@1143 | 127 # Enable php |
pascal@18730 | 128 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then |
pascal@18730 | 129 [ -f "$1/usr/lib/lighttpd/mod_fastcgi.so" ] || \ |
pascal@18730 | 130 tazpkg get-install lighttpd-modules --root="$1/" |
pascal@1143 | 131 sed -e 's|#fastcgi.server = ( ".php"|fastcgi.server = ( ".php"|' \ |
pascal@1143 | 132 -e 's|#"bin-path" => "/usr/bin/php-cgi"|"bin-path" => "/usr/bin/php-cgi"|' \ |
pascal@1143 | 133 -e 's|#"socket" => "/tmp/php.socket"|"socket" => "/tmp/php.socket"\n )))|' \ |
pascal@18730 | 134 -i "$1/etc/lighttpd/lighttpd.conf" |
pascal@18730 | 135 grep -q mod_fastcgi "$1/etc/lighttpd/lighttpd.conf" || \ |
pascal@1143 | 136 sed -e 's|server.modules = (|server.modules = (\n "mod_fastcgi",|' \ |
pascal@18730 | 137 -i "$1/etc/lighttpd/lighttpd.conf" |
pascal@18730 | 138 grep -q php3 "$1/etc/lighttpd/lighttpd.conf" || \ |
pascal@1635 | 139 sed -e 's|for PHP.*|for PHP.\nfastcgi.map-extensions = ( ".php3" => ".php", ".php4" => ".php", ".php5" => ".php" )|' \ |
pascal@18730 | 140 -i "$1/etc/lighttpd/lighttpd.conf" |
pascal@1143 | 141 fi |
pankso@18 | 142 # Start Web server. |
pascal@15149 | 143 if [ -z "$1" -a ! -f /var/run/lighttpd.pid \ |
pascal@15149 | 144 -a -f /etc/init.d/lighttpd ]; then |
pankso@18 | 145 /etc/init.d/lighttpd start |
pankso@18 | 146 fi |
pankso@18 | 147 } |