--- rpms/smeserver-php/sme10/smeserver-php.spec 2021/09/18 03:01:12 1.49 +++ rpms/smeserver-php/sme10/smeserver-php.spec 2021/10/24 05:58:25 1.51 @@ -1,5 +1,5 @@ %define version 3.0.0 -%define release 39 +%define release 41 %define name smeserver-php @@ -41,6 +41,8 @@ Patch27: smeserver-php-3.0.0-bz11452-bz5 Patch28: smeserver-php-3.0.0-bz11422-logging.patch Patch29: smeserver-php-3.0.0-bz11573.patch Patch30: smeserver-php-3.0.0-bz8077-bz11666.patch +Patch31: smeserver-php-3.0.0-bz11666-error_reporting.patch +Patch32: smeserver-php-3.0.0-bz11717-addphp81.patch BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot BuildArch: x86_64 @@ -243,6 +245,25 @@ Requires: php80-php-process Requires: php80-php-snmp Requires: php80-php, php80-php-enchant , php80-php-pdo php80-php-tidy , php80-php-mysqlnd php80-php-pecl-zip +# PHP 8.1 +Requires: php81-php-cli +Requires: php81-php-ldap +Requires: php81-php-imap +Requires: php81-php-gd +Requires: php81-php-xml +Requires: php81-php-xmlrpc +Requires: php81-php-soap +Requires: php81-php-opcache +Requires: php81-php-fpm +Requires: php81-php-mbstring +Requires: php81-php-json +Requires: php81-php-bcmath +Requires: php81-php-intl +Requires: php81-php-pear +Requires: php81-php-process +Requires: php81-php-snmp +Requires: php81-php, php81-php-enchant , php81-php-pdo php81-php-tidy , php81-php-mysqlnd php81-php-pecl-zip + %description Manage PHP FPM pools, and switch between PHP versions easily @@ -279,6 +300,8 @@ Manage PHP FPM pools, and switch between %patch28 -p1 %patch29 -p1 %patch30 -p1 +%patch31 -p1 +%patch32 -p1 %build perl createlinks @@ -298,7 +321,7 @@ echo "[Install]" > root/usr/lib/systemd/ echo "WantedBy=sme-server.target" > root/usr/lib/systemd/system/php-fpm.service.d/51koozali.conf %{__mkdir_p} root/etc/e-smith/templates.metadata/etc/logrotate.d/ -for phpver in "55" "56" "70" "71" "72" "73" "74" "80"; do +for phpver in "55" "56" "70" "71" "72" "73" "74" "80" "81"; do #needed folder %{__mkdir_p} root/var/log/php/php$phpver/ %{__mkdir_p} root/var/lib/php/php$phpver/{session,tmp,opcache,wsdlcache} @@ -308,12 +331,8 @@ for phpver in "55" "56" "70" "71" "72" " echo 'enabled' > root/etc/e-smith/db/configuration/defaults/php$phpver-php-fpm/status echo 'service'> root/etc/e-smith/db/configuration/defaults/php$phpver-php-fpm/type -#create service configuration for SME Seerver -#%{__mkdir_p} root/%{_unitdir}/php$phpver-php-fpm.service.d/ -#echo '' > root/%{_unitdir}/php$phpver-php-fpm.service.d/php$phpver-php-fpm.conf - -##enable by default php fpm -#echo 'enable php'$phpver'-php-fpm.service' >>root/%{_presetdir}/80-koozali-php.preset +echo 'configuration'> root/etc/e-smith/db/configuration/defaults/php$phpver/type +echo 'Off'> root/etc/e-smith/db/configuration/defaults/php$phpver/AllowUrlFopen #logrotate templates echo 'TEMPLATE_PATH="/etc/logrotate.d/php-fpm" @@ -337,7 +356,7 @@ find root/etc/e-smith/templates.metadata done # php7* -for phpver in "72" "73" "74" "80"; do +for phpver in "72" "73" "74" "80" "81"; do #cp ph70 metada mkdir -p root/etc/e-smith/templates.metadata/etc/opt/remi/php$phpver/ cp -a root/etc/e-smith/templates.metadata/etc/opt/remi/php70/* root/etc/e-smith/templates.metadata/etc/opt/remi/php$phpver/ @@ -346,10 +365,13 @@ find root/etc/e-smith/templates.metadata done # then patch the following files -#./templates/etc/logrotate.d/php-fpm/php-fpm: /sbin/e-smith/service php56-php-fpm reload >/dev/null 2>&1 || true -#./templates/etc/httpd/conf/httpd.conf/68FastCGIConfig: foreach my $ver ('', '56', '70', '71'){ -#./templates/etc/cron.daily/tmpwatch-php-fpm/10Defaults:for VER in php php56 php70 php71; do - +### TODO +### fix those files so we do not have to patch them, but generate them or sed them to change a known WORDTODOGENERIC +#smeserver-php-3.0.0/createlinks +#smeserver-php-3.0.0/root/etc/e-smith/templates/etc/cron.daily/tmpwatch-php-fpm/10Defaults +#smeserver-php-3.0.0/root/etc/e-smith/templates/etc/logrotate.d/php-fpm/php-fpm +#smeserver-php-3.0.0/root/etc/e-smith/templates/etc/rsyslog.conf/32php # this one could be cut in fragments per version +#smeserver-php-3.0.0/root/etc/e-smith/templates.metadata/etc/opt/remi/php81/php.ini %install /bin/rm -rf $RPM_BUILD_ROOT @@ -361,7 +383,7 @@ done --dir /var/lib/php/php/tmp 'attr(0770,root,www)' \ --dir /var/lib/php/php/opcache 'attr(0770,root,www)' \ --dir /var/lib/php/php/wsdlcache 'attr(0770,root,www)' \ -`for phpver in "54" "55" "56" "70" "71" "72" "73" "74" "80"; do echo -n "--dir /var/log/php/php$phpver attr(0770,root,www) --dir /var/lib/php/php$phpver/session attr(0770,root,www) --dir /var/lib/php/php$phpver/tmp attr(0770,root,www) --dir /var/lib/php/php$phpver/opcache attr(0770,root,www) --dir /var/lib/php/php$phpver/wsdlcache attr(0770,root,www) ";done ` \ +`for phpver in "54" "55" "56" "70" "71" "72" "73" "74" "80" "81"; do echo -n "--dir /var/log/php/php$phpver attr(0770,root,www) --dir /var/lib/php/php$phpver/session attr(0770,root,www) --dir /var/lib/php/php$phpver/tmp attr(0770,root,www) --dir /var/lib/php/php$phpver/opcache attr(0770,root,www) --dir /var/lib/php/php$phpver/wsdlcache attr(0770,root,www) ";done ` \ > %{name}-%{version}-filelist @@ -380,6 +402,12 @@ rm -rf $RPM_BUILD_ROOT %preun %changelog +* Sun Oct 24 2021 Jean-Philippe Pialasse 3.0.0-41.sme +- add php81 support [SME: 11717] + +* Fri Sep 24 2021 John Crisp 3.0.0-40.sme +- Fix incorrect commenting for error reporting + * Fri Sep 17 2021 Jean-Philippe Pialasse 3.0.0-39.sme - add ErrorReporting and DisplayErrors properties [SME: 8077] only per ibays (php defaults still hardcoded)