wok diff php-apache/receipt @ rev 25334

updated sunxi-tools (1.1-80 -> 1.4.2)
author Hans-G?nter Theisgen
date Sat Jul 23 17:16:06 2022 +0100 (2022-07-23)
parents b10d41313e54
children
line diff
     1.1 --- a/php-apache/receipt	Fri Mar 20 15:21:15 2020 +0100
     1.2 +++ b/php-apache/receipt	Sat Jul 23 17:16:06 2022 +0100
     1.3 @@ -1,42 +1,45 @@
     1.4  # SliTaz package receipt.
     1.5  
     1.6  PACKAGE="php-apache"
     1.7 -VERSION="7.3.16"
     1.8 +VERSION="7.4.4"
     1.9  CATEGORY="development"
    1.10  SHORT_DESC="PHP module for apache."
    1.11  MAINTAINER="pascal.bellard@slitaz.org"
    1.12  LICENSE="BSD"
    1.13  WEB_SITE="https://www.php.net/"
    1.14 +
    1.15 +PROVIDE="php:apache"
    1.16 +DEPENDS="apache libxml2 php-common zlib"
    1.17  WANTED="php"
    1.18 -PROVIDE="php:apache"
    1.19 -
    1.20 -DEPENDS="php-common apache libxml2 zlib"
    1.21  
    1.22  # Rules to gen a SliTaz package suitable for Tazpkg.
    1.23  genpkg_rules()
    1.24  {
    1.25  	mkdir -p $fs/usr/share
    1.26 -	cp -a $install/usr/share/apache $fs/usr/share
    1.27 +	cp -a $install/usr/share/apache	$fs/usr/share
    1.28  }
    1.29  
    1.30  # Post and pre install commans to stop
    1.31  # and restart Web server if needed.
    1.32  pre_install()
    1.33  {
    1.34 -	if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]; then
    1.35 +	if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]
    1.36 +	  then
    1.37  		/etc/init.d/apache stop
    1.38  	fi
    1.39  }
    1.40  
    1.41  post_install()
    1.42  {
    1.43 -	grep -q php5_module "$1/etc/apache/httpd.conf" || {
    1.44 +	grep -q php5_module "$1/etc/apache/httpd.conf" ||
    1.45 +	{
    1.46  	    sed -e 's|mod_rewrite.so|mod_rewrite.so\nLoadModule php5_module share/apache/modules/libphp5.so|' \
    1.47  	    	-e 's|DirectoryIndex index.html|DirectoryIndex index.html index.php|' \
    1.48  		-e 's|mime.types|mime.types\n    AddType application/x-httpd-php .php .php3 .php4 .php5\n    AddType application/x-httpd-php-source .phps|' \
    1.49  	        -i "$1/etc/apache/httpd.conf"
    1.50  	}
    1.51 -	[ -f "$1/etc/apache/conf.d/phpinfo" ] || \
    1.52 +
    1.53 +	[ -f "$1/etc/apache/conf.d/phpinfo" ] || 
    1.54  		cat > "$1/etc/apache/conf.d/phpinfo" <<EOT
    1.55  <IfModule mod_alias.c>
    1.56      Alias /phpinfo /usr/share/phpinfo
    1.57 @@ -49,13 +52,15 @@
    1.58      Allow from all
    1.59  </DirectoryMatch>
    1.60  EOT
    1.61 +
    1.62  	# Restart Web server.
    1.63 -	if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]; then
    1.64 +	if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]
    1.65 +	  then
    1.66  		/etc/init.d/apache stop
    1.67  		sleep 2
    1.68  	fi
    1.69 -	if [ -z "$1" ]; then
    1.70 +	if [ -z "$1" ]
    1.71 +	  then
    1.72  		/etc/init.d/apache start
    1.73  	fi
    1.74  }
    1.75 -