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