From 8ff3ef61a2e1cd3104766c445e9e58e20042822f Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Mon, 9 Dec 2024 21:08:42 +0100 Subject: [PATCH] - updated to 8.4.1 --- fix-test-run.patch | 19 ++- intl-stdc++.patch | 29 ++-- php-both-apxs.patch | 10 +- php-config-dir.patch | 17 +- php-db.patch | 52 +++--- php-dba-link.patch | 10 +- php-fcgi-graceful.patch | 4 +- php-include_path.patch | 10 +- php-ini.patch | 32 ++-- php-no_pear_install.patch | 12 +- php-nohttpd.patch | 48 +++++- php-oracle-instantclient.patch | 39 ----- php-paths.patch | 4 +- php-shared.patch | 96 +++++------ php-silent-session-cleanup.patch | 4 +- php-stupidapache_version.patch | 33 ++-- php-systzdata.patch | 155 ++++++++++++----- php-use-prog_sendmail.patch | 26 +-- php.spec | 275 ++++++++----------------------- 19 files changed, 404 insertions(+), 471 deletions(-) delete mode 100644 php-oracle-instantclient.patch diff --git a/fix-test-run.patch b/fix-test-run.patch index 7601cc1..dc98e5b 100644 --- a/fix-test-run.patch +++ b/fix-test-run.patch @@ -1,15 +1,16 @@ ---- php-5.4.0alpha2/configure.ac~ 2011-08-07 12:43:31.000000000 +0300 -+++ php-5.4.0alpha2/configure.ac 2011-08-07 12:44:11.495394662 +0300 -@@ -1271,6 +1271,9 @@ - AC_DEFINE_UNQUOTED(PHP_BUILD_ARCH,"$PHP_BUILD_ARCH",[build architecture]) - fi - +--- php-8.4.1/configure.ac~ 2024-11-22 11:30:13.000000000 +0100 ++++ php-8.4.1/configure.ac 2024-11-22 11:32:52.836654521 +0100 +@@ -1428,6 +1428,10 @@ PHP_SUBST([PHP_SAPI_OBJS]) + PHP_SUBST([PHP_BINARY_OBJS]) + PHP_SUBST([PHP_GLOBAL_OBJS]) + PHP_SUBST([PHP_BINARIES]) ++ +# shift so that extensions like xml are loaded first +PHP_MODULES=$(echo "$PHP_MODULES" | sed -e 's,\(.*\)\(\$(phplibdir)/xml.la \),\2\1,') + - PHP_SUBST_OLD(PHP_INSTALLED_SAPIS) - - PHP_SUBST(PHP_FASTCGI_OBJS) + PHP_SUBST([PHP_MODULES]) + PHP_SUBST([PHP_ZEND_EX]) + PHP_SUBST([bindir]) --- php-8.1.10/build/Makefile.global.orig 2022-09-25 19:52:15.520810107 +0200 +++ php-8.1.10/build/Makefile.global 2022-09-25 19:54:52.676625388 +0200 @@ -81,8 +81,15 @@ install-headers: diff --git a/intl-stdc++.patch b/intl-stdc++.patch index 3ad69f0..6045cf0 100644 --- a/intl-stdc++.patch +++ b/intl-stdc++.patch @@ -4,23 +4,24 @@ it's needed for ext/intl but it requires icu which already links with stdc++ so just omit PHP_ADD_LIBRARY(stdc++) ---- php-7.0.6/build/php.m4~ 2016-05-16 18:31:11.000000000 +0300 -+++ php-7.0.6/build/php.m4 2016-05-16 18:50:34.614991634 +0300 -@@ -762,7 +762,6 @@ - if test -z "$php_cxx_done"; then - AC_PROG_CXX - AC_PROG_CXXCPP -- PHP_ADD_LIBRARY(stdc++) - php_cxx_done=yes - fi +--- php-8.4.1/build/php.m4~ 2024-11-22 10:01:25.000000000 +0100 ++++ php-8.4.1/build/php.m4 2024-11-22 10:02:25.646654614 +0100 +@@ -757,7 +757,6 @@ AC_DEFUN([PHP_REQUIRE_CXX], [ + AS_VAR_IF([php_cxx_done],, [ + AC_PROG_CXX + AC_PROG_CXXCPP +- PHP_ADD_LIBRARY([stdc++]) + php_cxx_done=yes ]) ---- php-7.0.6/ext/intl/config.m4~ 2016-04-28 21:13:06.000000000 +0300 -+++ php-7.0.6/ext/intl/config.m4 2016-05-16 18:49:53.909531704 +0300 -@@ -6,6 +6,7 @@ + ]) +--- php-8.4.1/ext/intl/config.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/ext/intl/config.m4 2024-11-22 10:03:11.049987946 +0100 +@@ -4,6 +4,7 @@ PHP_ARG_ENABLE([intl], [Enable internationalization support])]) if test "$PHP_INTL" != "no"; then + dnl -lstdc++ not needed, will be inherited from icu - PHP_SETUP_ICU(INTL_SHARED_LIBADD) - PHP_SUBST(INTL_SHARED_LIBADD) + PHP_SETUP_ICU([INTL_SHARED_LIBADD]) + PHP_SUBST([INTL_SHARED_LIBADD]) INTL_COMMON_FLAGS="$ICU_CFLAGS -Wno-write-strings -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1" + diff --git a/php-both-apxs.patch b/php-both-apxs.patch index 13fde84..17daf9b 100644 --- a/php-both-apxs.patch +++ b/php-both-apxs.patch @@ -1,11 +1,11 @@ ---- php-8.0.0beta4/build/Makefile.global~ 2020-10-03 12:59:22.000000000 +0300 -+++ php-8.0.0beta4/build/Makefile.global 2020-10-03 13:02:40.788491363 +0300 -@@ -23,6 +23,12 @@ +--- php-8.4.1/build/Makefile.global~ 2024-11-22 11:10:34.000000000 +0100 ++++ php-8.4.1/build/Makefile.global 2024-11-22 11:11:22.486654532 +0100 +@@ -22,6 +22,12 @@ libphp.la: libphp_common.la $(PHP_SAPI_O $(LIBTOOL) --tag=CC --mode=link $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(phptempdir)/libphp_common.la $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ - -@$(LIBTOOL) --silent --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 + -@$(LIBTOOL) --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 +$(LIBTOOL_SAPI): libphp_common.la $(PHP_SAPI_OBJS) -+ $(LIBTOOL) --tag=CC --mode=link $(CC) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(phptempdir)/libphp_common.la $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ ++ $(LIBTOOL) --tag=CC --mode=link $(CC) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(phptempdir)/libphp_common.la $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ + -@$(LIBTOOL) --silent --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 + +libtool-sapi: $(LIBTOOL_SAPI) diff --git a/php-config-dir.patch b/php-config-dir.patch index 05158a3..a2959d9 100644 --- a/php-config-dir.patch +++ b/php-config-dir.patch @@ -8,20 +8,21 @@ exec_prefix="@exec_prefix@" version="@PHP_VERSION@" vernum="@PHP_VERSION_ID@" -@@ -53,6 +54,8 @@ +@@ -67,6 +67,8 @@ case "$1" in echo $extension_dir;; --include-dir) echo $include_dir;; +--sysconfdir) + echo $sysconfdir;; - --php-binary) - echo $php_binary;; - --php-sapis) -@@ -72,6 +75,7 @@ - --ldflags [$ldflags] + --lib-dir) + echo $lib_dir;; + --lib-embed) +@@ -97,6 +99,7 @@ Options: --libs [$libs] --extension-dir [$extension_dir] -+ --sysconfdir [$sysconfdir] --include-dir [$include_dir] ++ --sysconfdir [$sysconfdir] + --lib-dir [$lib_dir] + --lib-embed [$php_embed_lib] --man-dir [$man_dir] - --php-binary [$php_binary] + diff --git a/php-db.patch b/php-db.patch index 3b43a3f..b7b664a 100644 --- a/php-db.patch +++ b/php-db.patch @@ -1,18 +1,13 @@ ---- php-7.1.1/ext/dba/config.m4.orig 2017-01-17 21:44:40.000000000 +0100 -+++ php-7.1.1/ext/dba/config.m4 2017-01-27 22:08:45.385645468 +0100 -@@ -245,7 +245,7 @@ - ]])],[ - AC_EGREP_CPP(yes,[ - #include "$THIS_INCLUDE" --#if DB_VERSION_MAJOR == $1 || ($1 == 4 && DB_VERSION_MAJOR == 5) -+#if DB_VERSION_MAJOR == $1 || ($1 == 4 && (DB_VERSION_MAJOR == 5 || DB_VERSION_MAJOR == 6)) - yes - #endif - ],[ -@@ -322,10 +322,26 @@ +--- php-8.4.1/ext/dba/config.m4~ 2024-11-22 11:43:54.000000000 +0100 ++++ php-8.4.1/ext/dba/config.m4 2024-11-22 14:32:14.459988099 +0100 +@@ -459,6 +459,22 @@ if test "$PHP_DB4" != "no"; then THIS_PREFIX=$i - THIS_INCLUDE=$i/db4/db.h + THIS_INCLUDE=$i/include/db5.0/db.h break ++ elif test -f "$i/include/db5.2/db.h"; then ++ THIS_PREFIX=$i ++ THIS_INCLUDE=$i/include/db5.2/db.h ++ break + elif test -f "$i/include/db6.2/db.h"; then + THIS_PREFIX=$i + THIS_INCLUDE=$i/include/db6.2/db.h @@ -25,23 +20,16 @@ + THIS_PREFIX=$i + THIS_INCLUDE=$i/include/db6.0/db.h + break - elif test -f "$i/include/db5.3/db.h"; then + elif test -f "$i/include/db4.8/db.h"; then THIS_PREFIX=$i - THIS_INCLUDE=$i/include/db5.3/db.h - break -+ elif test -f "$i/include/db5.2/db.h"; then -+ THIS_PREFIX=$i -+ THIS_INCLUDE=$i/include/db5.2/db.h -+ break - elif test -f "$i/include/db5.1/db.h"; then - THIS_PREFIX=$i - THIS_INCLUDE=$i/include/db5.1/db.h -@@ -366,7 +384,7 @@ - break - fi - done -- PHP_DBA_DB_CHECK(4, db-5.3 db-5.1 db-5.0 db-4.8 db-4.7 db-4.6 db-4.5 db-4.4 db-4.3 db-4.2 db-4.1 db-4.0 db-4 db4 db, [(void)db_create((DB**)0, (DB_ENV*)0, 0)]) -+ PHP_DBA_DB_CHECK(4, db-6.2 db-6.1 db-6.0 db-5.3 db-5.2 db-5.1 db-5.0 db-4.8 db-4.7 db-4.6 db-4.5 db-4.4 db-4.3 db-4.2 db-4.1 db-4.0 db-4 db4 db, [(void)db_create((DB**)0, (DB_ENV*)0, 0)]) - fi - PHP_DBA_STD_RESULT(db4,Berkeley DB4) - + THIS_INCLUDE=$i/include/db4.8/db.h +@@ -498,6 +514,9 @@ if test "$PHP_DB4" != "no"; then + db-5.3 + db-5.1 + db-5.0 ++ db-6.2 ++ db-6.1 ++ db-6.0 + db-4.8 + db-4.7 + db-4.6 diff --git a/php-dba-link.patch b/php-dba-link.patch index 1479ac7..063338d 100644 --- a/php-dba-link.patch +++ b/php-dba-link.patch @@ -1,11 +1,11 @@ ---- php-5.2.3/ext/dba/config.m4~ 2007-06-01 10:47:16.524748906 +0300 -+++ php-5.2.3/ext/dba/config.m4 2007-06-01 10:51:16.450167741 +0300 -@@ -186,6 +186,8 @@ +--- php-8.4.1/ext/dba/config.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/ext/dba/config.m4 2024-11-22 11:04:01.633321209 +0100 +@@ -344,6 +344,8 @@ AC_DEFUN([PHP_DBA_DB_CHECK],[ #endif ],[ THIS_LIBS=$LIB + LDFLAGS=$old_LDFLAGS + LIBS=$old_LIBS lib_found=1 - ]) - ],[]) + ])], + [])]) diff --git a/php-fcgi-graceful.patch b/php-fcgi-graceful.patch index 96c6496..4c26509 100644 --- a/php-fcgi-graceful.patch +++ b/php-fcgi-graceful.patch @@ -20,7 +20,7 @@ echo "end!
\n"; --- php-7.1.0alpha2/sapi/cgi/cgi_main.c~ 2016-07-04 14:56:49.000000000 +0300 +++ php-7.1.0alpha2/sapi/cgi/cgi_main.c 2016-07-04 14:58:17.522958766 +0300 -@@ -101,6 +101,9 @@ +@@ -117,6 +117,9 @@ static int children = 0; */ static int parent = 1; @@ -29,7 +29,7 @@ echo "end!
\n"; + #ifndef PHP_WIN32 /* Did parent received exit signals SIG_TERM/SIG_INT/SIG_QUIT */ - static int exit_signal = 0; + static volatile sig_atomic_t exit_signal = 0; @@ -1221,6 +1224,21 @@ } #endif diff --git a/php-include_path.patch b/php-include_path.patch index d956cc7..2104389 100644 --- a/php-include_path.patch +++ b/php-include_path.patch @@ -1,9 +1,9 @@ ---- php-5.2.0/configure.ac.includedir -+++ php-5.2.0/configure.ac -@@ -1101,7 +1101,7 @@ +--- php-8.4.1/configure.ac~ 2024-11-22 11:28:31.000000000 +0100 ++++ php-8.4.1/configure.ac 2024-11-22 11:29:26.789987855 +0100 +@@ -1360,7 +1360,7 @@ EXPANDED_SYSCONFDIR=$(eval echo $sysconf EXPANDED_DATADIR=$datadir - EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"` - EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"` + EXPANDED_PHP_CONFIG_FILE_PATH=$(eval echo "$PHP_CONFIG_FILE_PATH") + EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=$(eval echo "$PHP_CONFIG_FILE_SCAN_DIR") -INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR +INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR:${EXPANDED_DATADIR}/php diff --git a/php-ini.patch b/php-ini.patch index f942f37..35d7cfe 100644 --- a/php-ini.patch +++ b/php-ini.patch @@ -1,5 +1,5 @@ ---- php-8.3.0/php.ini.orig 2023-11-21 15:40:35.000000000 +0100 -+++ php-8.3.0/php.ini 2023-12-05 13:00:42.746146357 +0100 +--- php-8.4.1/php.ini.orig 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/php.ini 2024-12-09 11:05:07.208307921 +0100 @@ -82,6 +82,16 @@ ; much more verbose when it comes to errors. We recommend using the ; development version only in development environments, as errors shown to @@ -17,8 +17,8 @@ ; This is the php.ini-production INI file. -@@ -150,7 +160,7 @@ - ; Production Value: 26 +@@ -140,7 +150,7 @@ + ; Production Value: 1000 ; short_open_tag -; Default Value: On @@ -26,7 +26,7 @@ ; Development Value: Off ; Production Value: Off -@@ -181,7 +191,7 @@ +@@ -171,7 +181,7 @@ ;user_ini.filename = ".user.ini" ; To disable this feature set this option to an empty value @@ -35,7 +35,7 @@ ; TTL for user-defined php.ini files (time-to-live) in seconds. Default is 300 seconds (5 minutes) ;user_ini.cache_ttl = 300 -@@ -201,7 +211,7 @@ +@@ -191,7 +201,7 @@ ; documents, however this remains supported for backward compatibility reasons. ; Note that this directive does not control the = 2.0.44 is required]) - fi + APXS_INCLUDEDIR=$($APXS -q INCLUDEDIR) + APXS_HTTPD=$($APXS -q SBINDIR)/$($APXS -q TARGET) +- AS_IF([test ! -x "$APXS_HTTPD"], [AC_MSG_ERROR(m4_text_wrap([ +- $APXS_HTTPD executable not found. Please, install Apache HTTP Server +- command-line utility. +- ]))]) + APXS_CFLAGS=$($APXS -q CFLAGS) + APU_BINDIR=$($APXS -q APU_BINDIR) +@@ -56,15 +52,6 @@ + dnl Check Apache version. The HTTPD_VERSION was added in Apache 2.4.17. + dnl Earlier versions can use the Apache HTTP Server command-line utility. + APACHE_VERSION=$($APXS -q HTTPD_VERSION 2>/dev/null) +- AS_VAR_IF([APACHE_VERSION],, [ +- ac_output=$($APXS_HTTPD -v 2>&1 | grep version | $SED -e 's/Oracle-HTTP-//') +- ac_IFS=$IFS +- IFS="- /. +-" +- set $ac_output +- IFS=$ac_IFS +- APACHE_VERSION="$4.$5.$6" +- ]) + AS_VERSION_COMPARE([$APACHE_VERSION], [2.4.0], + [AC_MSG_ERROR([Please note that Apache version >= 2.4 is required])]) + +@@ -120,10 +107,7 @@ + -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 + ]) + +- AS_IF([$APXS_HTTPD -V 2>/dev/null | grep 'threaded:.*yes' >/dev/null 2>&1], [ +- APACHE_THREADED_MPM=yes +- enable_zts=yes +- ], [APACHE_THREADED_MPM=no]) ++ [APACHE_THREADED_MPM=no] + + AC_CONFIG_COMMANDS([apache2handler], [AS_VAR_IF([enable_zts], [yes],, + [AS_VAR_IF([APACHE_THREADED_MPM], [no], diff --git a/php-oracle-instantclient.patch b/php-oracle-instantclient.patch deleted file mode 100644 index 79c08c6..0000000 --- a/php-oracle-instantclient.patch +++ /dev/null @@ -1,39 +0,0 @@ -checking Oracle Instant Client SDK header directory... configure: error: Oracle Instant Client SDK header files not found - ---- php-5.3.3/ext/oci8/config.m4.orig 2010-06-25 23:18:09.000000000 +0200 -+++ php-5.3.3/ext/oci8/config.m4 2010-09-10 19:37:23.484315002 +0200 -@@ -304,6 +304,9 @@ - - AC_MSG_CHECKING([Oracle Instant Client SDK header directory]) - -+ dnl Header directory for Instant Client SDK PLD RPM install -+ OCISDKPLDINC=$PHP_OCI8_INSTANT_CLIENT/../include/oracle/client -+ - dnl Header directory for Instant Client SDK RPM install - OCISDKRPMINC=`echo "$PHP_OCI8_INSTANT_CLIENT" | $PHP_OCI8_SED -e 's!^/usr/lib/oracle/\(.*\)/client\('${PHP_OCI8_IC_LIBDIR_SUFFIX}'\)*/lib[/]*$!/usr/include/oracle/\1/client\2!'` - -@@ -313,7 +316,11 @@ - dnl Header directory for manual installation - OCISDKMANINC=`echo "$PHP_OCI8_INSTANT_CLIENT" | $PHP_OCI8_SED -e 's!\(.*\)/lib[/]*$!\1/include!'` - -- if test -f "$OCISDKRPMINC/oci.h"; then -+ if test -f "$OCISDKPLDINC/oci.h"; then -+ AC_MSG_RESULT($OCISDKPLDINC) -+ PHP_ADD_INCLUDE($OCISDKPLDINC) -+ OCI8INCDIR=$OCISDKPLDINC -+ elif test -f "$OCISDKRPMINC/oci.h"; then - AC_MSG_RESULT($OCISDKRPMINC) - PHP_ADD_INCLUDE($OCISDKRPMINC) - OCI8INCDIR=$OCISDKRPMINC ---- php-7.2.0RC1/ext/pdo_oci/config.m4~ 2017-09-11 14:32:13.000000000 +0300 -+++ php-7.2.0RC1/ext/pdo_oci/config.m4 2017-09-11 14:45:25.019346828 +0300 -@@ -113,6 +113,9 @@ - elif test -f "$OCISDKZIPINC/oci.h" ; then - PHP_ADD_INCLUDE($OCISDKZIPINC) - AC_MSG_RESULT($OCISDKZIPINC) -+ elif test -f $PDO_OCI_LIB_DIR/../include/oracle/client/oci.h ; then -+ PHP_ADD_INCLUDE($PDO_OCI_LIB_DIR/../include/oracle/client) -+ AC_MSG_RESULT($PDO_OCI_LIB_DIR/../include/oracle/client) - else - AC_MSG_ERROR([I'm too dumb to figure out where the include dir is in your Instant Client install]) - fi diff --git a/php-paths.patch b/php-paths.patch index a54fd6d..a31faf5 100644 --- a/php-paths.patch +++ b/php-paths.patch @@ -1,7 +1,7 @@ diff -ur php-7.1.1.orig/scripts/Makefile.frag php-7.1.1/scripts/Makefile.frag --- php-7.1.1.orig/scripts/Makefile.frag 2017-01-17 20:44:42.000000000 +0000 +++ php-7.1.1/scripts/Makefile.frag 2017-02-08 14:41:37.810333971 +0000 -@@ -3,8 +3,8 @@ +@@ -2,8 +2,8 @@ # Build environment install # @@ -21,9 +21,9 @@ diff -ur php-7.1.1.orig/scripts/php-config.in php-7.1.1/scripts/php-config.in vernum="@PHP_VERSION_ID@" -include_dir="@includedir@/php" +include_dir="@includedir@/php/php@program_suffix@" + lib_dir="@orig_libdir@" includes="-I$include_dir -I$include_dir/main -I$include_dir/TSRM -I$include_dir/Zend -I$include_dir/ext -I$include_dir/ext/date/lib" ldflags="@PHP_LDFLAGS@" - libs="@EXTRA_LIBS@" diff -ur php-7.1.1.orig/scripts/phpize.in php-7.1.1/scripts/phpize.in --- php-7.1.1.orig/scripts/phpize.in 2017-01-17 20:44:42.000000000 +0000 +++ php-7.1.1/scripts/phpize.in 2017-02-08 14:41:37.810333971 +0000 diff --git a/php-shared.patch b/php-shared.patch index 5683a4b..6fcf466 100644 --- a/php-shared.patch +++ b/php-shared.patch @@ -8,8 +8,8 @@ +PHP_BUILD_SHARED + dnl Checks for some support/generator progs. - PHP_PROG_AWK PHP_PROG_BISON([3.0.0]) + PHP_PROG_RE2C([1.0.3], [--no-generation-date]) --- php-8.0.0beta4/build/Makefile.global~ 2020-09-28 07:54:00.000000000 +0300 +++ php-8.0.0beta4/build/Makefile.global 2020-09-28 07:54:42.203157017 +0300 @@ -13,8 +13,12 @@ @@ -19,12 +19,12 @@ -libphp.la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) - $(LIBTOOL) --tag=CC --mode=link $(CC) $(LIBPHP_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ +libphp_common.la: $(PHP_GLOBAL_OBJS) -+ $(LIBTOOL) --tag=CC --mode=link $(CC) $(LIBPHP_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) -avoid-version $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ -release $(PHP_VERSION) -+ -@$(LIBTOOL) --silent --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 ++ $(LIBTOOL) --tag=CC --mode=link $(CC) $(LIBPHP_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) -avoid-version $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ -release $(PHP_MAJOR_VERSION).$(PHP_MINOR_VERSION).$(PHP_RELEASE_VERSION) ++ -@$(LIBTOOL) --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 + +libphp.la: libphp_common.la $(PHP_SAPI_OBJS) + $(LIBTOOL) --tag=CC --mode=link $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(phptempdir)/libphp_common.la $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ - -@$(LIBTOOL) --silent --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 + -@$(LIBTOOL) --tag=CC --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1 libs/libphp.bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) @@ -31,10 +31,10 @@ @@ -41,17 +41,17 @@ break; \ fi; \ done; \ ---- php-8.0.0beta4/sapi/cgi/config9.m4~ 2020-09-15 21:36:33.000000000 +0300 -+++ php-8.0.0beta4/sapi/cgi/config9.m4 2020-09-28 08:00:34.341402924 +0300 -@@ -55,7 +55,7 @@ - BUILD_CGI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" - ;; - *) -- BUILD_CGI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" -+ BUILD_CGI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" - ;; - esac - +--- php-8.4.1/sapi/cgi/config9.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/sapi/cgi/config9.m4 2024-11-22 09:49:54.616654636 +0100 +@@ -42,7 +42,7 @@ if test "$PHP_CGI" != "no"; then + [*darwin*], [ + BUILD_CGI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" + ], [ +- BUILD_CGI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" ++ BUILD_CGI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)" + ]) + + PHP_SUBST([SAPI_CGI_PATH]) --- php-7.0.0beta1/sapi/cgi/Makefile.frag~ 2015-07-10 15:11:43.000000000 +0300 +++ php-7.0.0beta1/sapi/cgi/Makefile.frag 2015-07-13 16:03:56.810212555 +0300 @@ -1,6 +1,6 @@ @@ -62,17 +62,17 @@ $(BUILD_CGI) install-cgi: $(SAPI_CGI_PATH) ---- php-8.0.0beta4/sapi/cli/config.m4~ 2020-09-15 21:36:33.000000000 +0300 -+++ php-8.0.0beta4/sapi/cli/config.m4 2020-09-28 10:50:26.427391375 +0300 -@@ -42,7 +42,7 @@ - BUILD_CLI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)" - ;; - *) -- BUILD_CLI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)" -+ BUILD_CLI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) \$(READLINE_SHARED_LIBADD) -o \$(SAPI_CLI_PATH)" - ;; - esac - +--- php-8.4.1/sapi/cli/config.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/sapi/cli/config.m4 2024-11-22 09:53:46.213321291 +0100 +@@ -46,7 +46,7 @@ if test "$PHP_CLI" != "no"; then + [*darwin*], [ + BUILD_CLI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)" + ], [ +- BUILD_CLI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)" ++ BUILD_CLI="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)" + ]) + + dnl Set executable for tests. --- php-5.4.0alpha2/sapi/cli/Makefile.frag~ 2011-01-24 00:40:35.000000000 +0200 +++ php-5.4.0alpha2/sapi/cli/Makefile.frag 2011-08-01 12:22:28.627926487 +0300 @@ -1,6 +1,6 @@ @@ -128,28 +128,28 @@ $(BUILD_LITESPEED) install-litespeed: $(SAPI_LITESPEED_PATH) ---- php-8.0.0beta4/sapi/litespeed/config.m4~ 2020-09-15 21:36:33.000000000 +0300 -+++ php-8.0.0beta4/sapi/litespeed/config.m4 2020-10-02 17:31:51.010389005 +0300 -@@ -18,7 +18,7 @@ - BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_LITESPEED_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" - ;; - *) -- BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" -+ BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" - ;; - esac - ---- php-8.0.0beta4/sapi/fpm/config.m4~ 2020-09-15 21:36:33.000000000 +0300 -+++ php-8.0.0beta4/sapi/fpm/config.m4 2020-10-02 17:33:05.217571527 +0300 -@@ -659,7 +659,7 @@ - BUILD_FPM="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" - ;; - *) -- BUILD_FPM="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" -+ BUILD_FPM="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" - ;; - esac - +--- php-8.4.1/sapi/litespeed/config.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/sapi/litespeed/config.m4 2024-11-22 09:58:29.276654616 +0100 +@@ -18,7 +18,7 @@ if test "$PHP_LITESPEED" != "no"; then + SAPI_LITESPEED_PATH=sapi/litespeed/php.exe + BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_LITESPEED_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" + ], [ +- BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" ++ BUILD_LITESPEED="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)" + ]) + + PHP_SUBST([SAPI_LITESPEED_PATH]) +--- php-8.4.1/sapi/fpm/config.m4~ 2024-11-20 10:48:35.000000000 +0100 ++++ php-8.4.1/sapi/fpm/config.m4 2024-11-22 09:59:28.119987949 +0100 +@@ -567,7 +567,7 @@ if test "$PHP_FPM" != "no"; then + [*darwin*], [ + BUILD_FPM="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" + ], [ +- BUILD_FPM="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" ++ BUILD_FPM="\$(LIBTOOL) --tag=CC --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) libphp_common.la \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" + ]) + + PHP_SUBST([SAPI_FPM_PATH]) --- php-7.0.0beta1/sapi/fpm/Makefile.frag~ 2015-07-15 13:54:11.000000000 +0300 +++ php-7.0.0beta1/sapi/fpm/Makefile.frag 2015-07-15 13:56:12.116885111 +0300 @@ -1,6 +1,6 @@ diff --git a/php-silent-session-cleanup.patch b/php-silent-session-cleanup.patch index 0d37d8d..12b3015 100644 --- a/php-silent-session-cleanup.patch +++ b/php-silent-session-cleanup.patch @@ -1,5 +1,5 @@ ---- php-8.2.5/ext/session/mod_files.c.orig 2023-04-24 11:42:37.515845438 +0200 -+++ php-8.2.5/ext/session/mod_files.c 2023-04-24 11:45:46.013854719 +0200 +--- php-8.2.0RC2/ext/session/mod_files.c~ 2022-09-14 12:42:49.000000000 +0300 ++++ php-8.2.0RC2/ext/session/mod_files.c 2022-09-29 01:26:03.341783642 +0300 @@ -287,7 +287,6 @@ dir = opendir(ZSTR_VAL(dirname)); diff --git a/php-stupidapache_version.patch b/php-stupidapache_version.patch index e8ae17b..f8426e3 100644 --- a/php-stupidapache_version.patch +++ b/php-stupidapache_version.patch @@ -1,18 +1,29 @@ ---- php-5.4.0alpha2/build/php.m4 2011-08-07 21:13:21.581133944 +0300 -+++ php-5.4.0alpha2/build/php.m4 2011-08-07 21:10:21.766717150 +0300 -@@ -2607,7 +2609,14 @@ - dnl This macro is used to get a comparable version for Apache. +--- php-8.4.1/build/php.m4~ 2024-11-22 15:00:06.000000000 +0100 ++++ php-8.4.1/build/php.m4 2024-11-22 15:03:55.783321362 +0100 +@@ -2036,6 +2036,18 @@ dnl This macro is used to get a comparab dnl - AC_DEFUN([PHP_AP_EXTRACT_VERSION],[ -- ac_output=`$1 -v 2>&1 | grep version | $SED -e 's/Oracle-HTTP-//'` + AC_DEFUN([PHP_AP_EXTRACT_VERSION], [m4_warn([obsolete], + [The macro 'PHP_AP_EXTRACT_VERSION' is obsolete. Use 'apxs -q HTTPD_VERSION']) + PHP_ARG_WITH(apache-version, Set Apache version, + [ --with-apache-version=VERSION Set Apache version instead of detecting from httpd binary]) -+ + if test "$with_apache_version" != "no"; then + ac_output="foo bar baz $with_apache_version" ++ ac_IFS=$IFS ++IFS="- /. ++" ++ set $ac_output ++ IFS=$ac_IFS ++ ++ APACHE_VERSION=$(expr [$]4 \* 1000000 + [$]5 \* 1000 + [$]6) + else -+ ac_output=`$1 -v 2>&1 | grep version | $SED -e 's/Oracle-HTTP-//'` -+ fi + AS_IF([test -x "$1"], [ + ac_output=$($1 -v 2>&1 | grep version | $SED -e 's/Oracle-HTTP-//') ac_IFS=$IFS - IFS="- /. - " +@@ -2046,6 +2058,7 @@ IFS="- /. + + APACHE_VERSION=$(expr [$]4 \* 1000000 + [$]5 \* 1000 + [$]6) + ]) ++ fi + ]) + + dnl diff --git a/php-systzdata.patch b/php-systzdata.patch index 61697eb..6176a8b 100644 --- a/php-systzdata.patch +++ b/php-systzdata.patch @@ -5,6 +5,9 @@ Add support for use of the system timezone database, rather than embedding a copy. Discussed upstream but was not desired. History: +r24: add internal UTC if tzdata is missing +r23: fix possible buffer overflow +r22: retrieve tzdata version from /usr/share/zoneinfo/tzdata.zi r21: adapt for timelib 2021.03 (in 8.1.0) r20: adapt for timelib 2020.03 (in 8.0.10RC1) r19: adapt for timelib 2020.02 (in 8.0.0beta2) @@ -32,10 +35,33 @@ r3: fix a crash if /usr/share/zoneinfo doesn't exist (Raphael Geissert) r2: add filesystem trawl to set up name alias index r1: initial revision -diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/date/lib/parse_tz.c ---- php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata 2020-09-01 19:13:26.000000000 +0200 -+++ php-8.0.0beta3/ext/date/lib/parse_tz.c 2020-09-02 08:07:51.039979873 +0200 -@@ -26,9 +26,22 @@ + +diff -up ./ext/date/config0.m4.systzdata ./ext/date/config0.m4 +--- ./ext/date/config0.m4.systzdata 2024-07-03 16:21:20.240786848 +0200 ++++ ./ext/date/config0.m4 2024-07-03 16:25:14.838995464 +0200 +@@ -8,6 +8,18 @@ + [PHP_DATE_CFLAGS="$PHP_DATE_CFLAGS -Wno-implicit-fallthrough"],, + [-Werror]) + ++PHP_ARG_WITH(system-tzdata, for use of system timezone data, ++ [AS_HELP_STRING([--with-system-tzdata[=DIR]],[to specify use of system timezone data])], no, no) ++ ++if test "$PHP_SYSTEM_TZDATA" != "no"; then ++ AC_DEFINE(HAVE_SYSTEM_TZDATA, 1, [Define if system timezone data is used]) ++ ++ if test "$PHP_SYSTEM_TZDATA" != "yes"; then ++ AC_DEFINE_UNQUOTED(HAVE_SYSTEM_TZDATA_PREFIX, "$PHP_SYSTEM_TZDATA", ++ [Define for location of system timezone data]) ++ fi ++fi ++ + PHP_DATE_CFLAGS="$PHP_DATE_CFLAGS -I@ext_builddir@/lib -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -DHAVE_TIMELIB_CONFIG_H=1" + timelib_sources="lib/astro.c lib/dow.c lib/parse_date.c lib/parse_tz.c lib/parse_posix.c + lib/timelib.c lib/tm2unixtime.c lib/unixtime2tm.c lib/parse_iso_intervals.c lib/interval.c" +diff -up ./ext/date/lib/parse_tz.c.systzdata ./ext/date/lib/parse_tz.c +--- ./ext/date/lib/parse_tz.c.systzdata 2024-07-02 15:43:13.000000000 +0200 ++++ ./ext/date/lib/parse_tz.c 2024-07-03 16:21:20.240786848 +0200 +@@ -26,9 +26,33 @@ #include "timelib.h" #include "timelib_private.h" @@ -48,6 +74,17 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + +#include "php_scandir.h" + ++static const unsigned char internal_utc[] = { ++ 0x54, 0x5a, 0x69, 0x66, 0x32, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, ++ 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x54, 0x5a, 0x69, 0x66, 0x32, 0x00, 0x00, 0x00, 0x00, 0x00, ++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, ++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, ++ 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x0a, 0x55, 0x54, 0x43, ++ 0x30, 0x0a ++}; ++ +#else #define TIMELIB_SUPPORTS_V2DATA #define TIMELIB_SUPPORT_SLIM_FILE @@ -58,7 +95,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat #if (defined(__APPLE__) || defined(__APPLE_CC__)) && (defined(__BIG_ENDIAN__) || defined(__LITTLE_ENDIAN__)) # if defined(__LITTLE_ENDIAN__) -@@ -95,6 +108,11 @@ static int read_php_preamble(const unsig +@@ -95,6 +119,11 @@ static int read_php_preamble(const unsig { uint32_t version; @@ -70,7 +107,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat /* read ID */ version = (*tzf)[3] - '0'; *tzf += 4; -@@ -577,7 +595,429 @@ void timelib_dump_tzinfo(timelib_tzinfo +@@ -577,7 +606,475 @@ void timelib_dump_tzinfo(timelib_tzinfo } } @@ -300,6 +337,44 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + return timelib_strcasecmp(alpha->id, beta->id); +} + ++/* Retrieve tzdata version. */ ++static void retrieve_zone_version(timelib_tzdb *db) ++{ ++ static char buf[30]; ++ char path[PATH_MAX]; ++ FILE *fp; ++ ++ strncpy(path, ZONEINFO_PREFIX "/tzdata.zi", sizeof(path)); ++ ++ fp = fopen(path, "r"); ++ if (fp) { ++ if (fgets(buf, sizeof(buf), fp)) { ++ if (!memcmp(buf, "# version ", 10) && ++ isdigit(buf[10]) && ++ isdigit(buf[11]) && ++ isdigit(buf[12]) && ++ isdigit(buf[13]) && ++ islower(buf[14])) { ++ if (buf[14] >= 't') { /* 2022t = 2022.20 */ ++ buf[17] = 0; ++ buf[16] = buf[14] - 't' + '0'; ++ buf[15] = '2'; ++ } else if (buf[14] >= 'j') { /* 2022j = 2022.10 */ ++ buf[17] = 0; ++ buf[16] = buf[14] - 'j' + '0'; ++ buf[15] = '1'; ++ } else { /* 2022a = 2022.1 */ ++ buf[16] = 0; ++ buf[15] = buf[14] - 'a' + '1'; ++ } ++ buf[14] = '.'; ++ db->version = buf+10; ++ } ++ } ++ fclose(fp); ++ } ++} ++ + +/* Create the zone identifier index by trawling the filesystem. */ +static void create_zone_index(timelib_tzdb *db) @@ -376,6 +451,9 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + + qsort(db_index, index_next, sizeof *db_index, sysdbcmp); + ++ if (!index_next) { ++ db_index[index_next++].id = strdup("UTC"); ++ } + db->index = db_index; + db->index_size = index_next; + @@ -392,7 +470,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + size_t n; + char *data, *p; + -+ data = malloc(3 * sysdb->index_size + 7); ++ data = malloc(3 * sysdb->index_size + sizeof(FAKE_HEADER) - 1); + + p = mempcpy(data, FAKE_HEADER, sizeof(FAKE_HEADER) - 1); + @@ -482,7 +560,12 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + + fd = open(fname, O_RDONLY); + if (fd == -1) { -+ return NULL; ++ if (strcmp(timezone, "UTC")) { ++ return NULL; ++ } else { ++ *length = sizeof(internal_utc); ++ return internal_utc; ++ } + } else if (fstat(fd, &st) != 0 || !is_valid_tzfile(&st, fd)) { + close(fd); + return NULL; @@ -501,7 +584,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat { int left = 0, right = tzdb->index_size - 1; -@@ -603,9 +1043,48 @@ static int seek_to_tz_position(const uns +@@ -603,9 +1100,49 @@ static int seek_to_tz_position(const uns return 0; } @@ -535,9 +618,10 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + if (timezonedb_system == NULL) { + timelib_tzdb *tmp = malloc(sizeof *tmp); + -+ tmp->version = "0.system"; ++ tmp->version = "0"; + tmp->data = NULL; + create_zone_index(tmp); ++ retrieve_zone_version(tmp); + system_location_table = create_location_table(); + fake_data_segment(tmp, system_location_table); + timezonedb_system = tmp; @@ -550,7 +634,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat } const timelib_tzdb_index_entry *timelib_timezone_identifiers_list(const timelib_tzdb *tzdb, int *count) -@@ -617,7 +1096,30 @@ const timelib_tzdb_index_entry *timelib_ +@@ -617,7 +1154,32 @@ const timelib_tzdb_index_entry *timelib_ int timelib_timezone_id_is_valid(const char *timezone, const timelib_tzdb *tzdb) { const unsigned char *tzf; @@ -564,7 +648,9 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + if (timezone[0] == '\0' || strstr(timezone, "..") != NULL) { + return 0; + } -+ ++ if (!strcmp(timezone, "UTC")) { ++ return 1; ++ } + if (system_location_table) { + if (find_zone_info(system_location_table, timezone) != NULL) { + /* found in cache */ @@ -582,7 +668,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat } static int skip_64bit_preamble(const unsigned char **tzf, timelib_tzinfo *tz) -@@ -662,6 +1164,8 @@ static timelib_tzinfo* timelib_tzinfo_ct +@@ -662,6 +1224,8 @@ static timelib_tzinfo* timelib_tzinfo_ct timelib_tzinfo *timelib_parse_tzfile(const char *timezone, const timelib_tzdb *tzdb, int *error_code) { const unsigned char *tzf; @@ -591,7 +677,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat timelib_tzinfo *tmp; int version; int transitions_result, types_result; -@@ -669,7 +1173,7 @@ timelib_tzinfo *timelib_parse_tzfile(con +@@ -669,7 +1233,7 @@ timelib_tzinfo *timelib_parse_tzfile(con *error_code = TIMELIB_ERROR_NO_ERROR; @@ -600,7 +686,7 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat tmp = timelib_tzinfo_ctor(timezone); version = read_preamble(&tzf, tmp, &type); -@@ -712,11 +1216,36 @@ timelib_tzinfo *timelib_parse_tzfile(con +@@ -712,11 +1276,38 @@ timelib_tzinfo *timelib_parse_tzfile(con return NULL; } @@ -623,7 +709,9 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat + } + + /* Now done with the mmap segment - discard it. */ -+ munmap(memmap, maplen); ++ if (memmap != internal_utc) { ++ munmap(memmap, maplen); ++ } + } else { +#endif if (type == TIMELIB_TZINFO_PHP) { @@ -637,25 +725,18 @@ diff -up php-8.0.0beta3/ext/date/lib/parse_tz.c.systzdata php-8.0.0beta3/ext/dat } else { *error_code = TIMELIB_ERROR_NO_SUCH_TIMEZONE; tmp = NULL; ---- php-8.3.11/ext/date/config0.m4.orig 2024-09-26 10:34:44.847065799 +0200 -+++ php-8.3.11/ext/date/config0.m4 2024-09-26 10:37:07.671368751 +0200 -@@ -8,6 +8,19 @@ - [PHP_DATE_CFLAGS="$PHP_DATE_CFLAGS -Wno-implicit-fallthrough"],, - [-Werror]) +diff -up ./ext/date/php_date.c.systzdata ./ext/date/php_date.c +--- ./ext/date/php_date.c.systzdata 2024-07-02 15:43:13.000000000 +0200 ++++ ./ext/date/php_date.c 2024-07-03 16:21:20.240786848 +0200 +@@ -487,7 +487,11 @@ PHP_MINFO_FUNCTION(date) + php_info_print_table_row(2, "date/time support", "enabled"); + php_info_print_table_row(2, "timelib version", TIMELIB_ASCII_VERSION); + php_info_print_table_row(2, "\"Olson\" Timezone Database Version", tzdb->version); ++#ifdef HAVE_SYSTEM_TZDATA ++ php_info_print_table_row(2, "Timezone Database", "system"); ++#else + php_info_print_table_row(2, "Timezone Database", php_date_global_timezone_db_enabled ? "external" : "internal"); ++#endif + php_info_print_table_row(2, "Default timezone", guess_timezone(tzdb)); + php_info_print_table_end(); -+PHP_ARG_WITH(system-tzdata, for use of system timezone data, -+[ --with-system-tzdata[=DIR] to specify use of system timezone data], -+no, no) -+ -+if test "$PHP_SYSTEM_TZDATA" != "no"; then -+ AC_DEFINE(HAVE_SYSTEM_TZDATA, 1, [Define if system timezone data is used]) -+ -+ if test "$PHP_SYSTEM_TZDATA" != "yes"; then -+ AC_DEFINE_UNQUOTED(HAVE_SYSTEM_TZDATA_PREFIX, "$PHP_SYSTEM_TZDATA", -+ [Define for location of system timezone data]) -+ fi -+fi -+ - PHP_DATE_CFLAGS="$PHP_DATE_CFLAGS -I@ext_builddir@/lib -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -DHAVE_TIMELIB_CONFIG_H=1" - timelib_sources="lib/astro.c lib/dow.c lib/parse_date.c lib/parse_tz.c lib/parse_posix.c - lib/timelib.c lib/tm2unixtime.c lib/unixtime2tm.c lib/parse_iso_intervals.c lib/interval.c" diff --git a/php-use-prog_sendmail.patch b/php-use-prog_sendmail.patch index dafbcd5..2b68b8e 100644 --- a/php-use-prog_sendmail.patch +++ b/php-use-prog_sendmail.patch @@ -1,15 +1,17 @@ ---- php-8.0.0rc1/build/php.m4~ 2020-10-09 18:56:11.000000000 +0300 -+++ php-8.0.0rc1/build/php.m4 2020-10-09 18:58:11.039360902 +0300 -@@ -1710,8 +1710,10 @@ +--- php-8.4.1/build/php.m4~ 2024-11-22 11:25:49.000000000 +0100 ++++ php-8.4.1/build/php.m4 2024-11-22 11:27:58.516654519 +0100 +@@ -1602,9 +1602,11 @@ dnl dnl Search for the sendmail binary. dnl - AC_DEFUN([PHP_PROG_SENDMAIL], [ -- PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib -- AC_PATH_PROG(PROG_SENDMAIL, sendmail, /usr/sbin/sendmail, $PATH:$PHP_ALT_PATH) -+ if test -z "$PROG_SENDMAIL"; then -+ PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib -+ AC_PATH_PROG(PROG_SENDMAIL, sendmail, /usr/sbin/sendmail, $PATH:$PHP_ALT_PATH) -+ fi - PHP_SUBST(PROG_SENDMAIL) - ]) + AC_DEFUN([PHP_PROG_SENDMAIL], +-[PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib +-AC_PATH_PROG([PROG_SENDMAIL], [sendmail], [], [$PATH:$PHP_ALT_PATH]) +-AS_VAR_IF([PROG_SENDMAIL],, [PROG_SENDMAIL=/usr/sbin/sendmail ++[if test -z "$PROG_SENDMAIL"; then ++ PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib ++ AC_PATH_PROG([PROG_SENDMAIL], [sendmail], [], [$PATH:$PHP_ALT_PATH]) ++fi ++ AS_VAR_IF([PROG_SENDMAIL],, [PROG_SENDMAIL=/usr/sbin/sendmail + AC_MSG_NOTICE([default sendmail_path INI directive set to $PROG_SENDMAIL])])]) + dnl diff --git a/php.spec b/php.spec index e214cdf..a9a3064 100644 --- a/php.spec +++ b/php.spec @@ -1,78 +1,72 @@ # Conditional build: # - General options: -%bcond_with embed # disable building Embedded API -%bcond_with gcov # Enable Code coverage reporting -%bcond_without kerberos5 # without Kerberos5 support +%bcond_with embed # Embedded API +%bcond_with gcov # Code coverage reporting %bcond_with systemtap # systemtap/DTrace support %bcond_with tests # default off; test process very often hangs on builders, approx run time 45m; perform "make test" %bcond_with zts # Zend Thread Safety %bcond_with debug # Zend Debug Build # - SAPI -%bcond_without apache2 # disable building Apache 2.x SAPI -%bcond_without cgi # disable CGI/FCGI SAPI -%bcond_without fpm # disable FPM SAPI -%bcond_without litespeed # build litespeed SAPI -%bcond_without phpdbg # disable phpdbg SAPI +%bcond_without apache2 # building Apache 2.x SAPI +%bcond_without cgi # CGI/FCGI SAPI +%bcond_without fpm # FPM SAPI +%bcond_without litespeed # litespeed SAPI +%bcond_without phpdbg # phpdbg SAPI # - Extensions -%bcond_without bcmath # without bcmath extension module -%bcond_without bzip2 # without bz2 extension module -%bcond_without calendar # without calendar extension module -%bcond_without ctype # without ctype extension module -%bcond_without curl # without CURL extension module -%bcond_without dba # without DBA extension module -%bcond_without dom # without DOM extension module -%bcond_without enchant # without Enchant extension module -%bcond_without exif # without EXIF extension module -%bcond_without ffi # without FFI extension module -%bcond_without fileinfo # without fileinfo extension module -%bcond_without filter # without filter extension module -%bcond_without ftp # without FTP extension module -%bcond_without gd # without GD extension module -%bcond_without gettext # without gettext extension module -%bcond_without gmp # without gmp extension module -%bcond_without iconv # without iconv extension module -%bcond_with imap # without IMAP extension module -%bcond_without intl # without Intl extension module -%bcond_without ldap # without LDAP extension module -%bcond_without mbstring # without mbstring extension module -%bcond_without mhash # without mhash extension (supported by hash extension) -%bcond_without mysqli # without mysqli support (Requires mysql >= 4.1) -%bcond_without mysqlnd # without mysqlnd support in mysql related extensions -%bcond_with oci # with Oracle oci8 extension module (BR: proprietary libs) -%bcond_without odbc # without ODBC extension module -%bcond_without opcache # without Enable Zend OPcache extension support -%bcond_without openssl # without OpenSSL support and OpenSSL extension (module) -%bcond_without pcntl # without pcntl extension module +%bcond_without bcmath # bcmath extension module +%bcond_without bzip2 # bz2 extension module +%bcond_without calendar # calendar extension module +%bcond_without ctype # ctype extension module +%bcond_without curl # CURL extension module +%bcond_without dba # DBA extension module +%bcond_without dom # DOM extension module +%bcond_without enchant # Enchant extension module +%bcond_without exif # EXIF extension module +%bcond_without ffi # FFI extension module +%bcond_without fileinfo # fileinfo extension module +%bcond_without filter # filter extension module +%bcond_without ftp # FTP extension module +%bcond_without gd # GD extension module +%bcond_without gettext # gettext extension module +%bcond_without gmp # gmp extension module +%bcond_without iconv # iconv extension module +%bcond_without intl # Intl extension module +%bcond_without ldap # LDAP extension module +%bcond_without mbstring # mbstring extension module +%bcond_without mhash # mhash extension (supported by hash extension) +%bcond_without mysqli # mysqli support (Requires mysql >= 4.1) +%bcond_without mysqlnd # mysqlnd support in mysql related extensions +%bcond_without odbc # ODBC extension module +%bcond_without opcache # Enable Zend OPcache extension support +%bcond_without openssl # OpenSSL support and OpenSSL extension (module) +%bcond_without pcntl # pcntl extension module %bcond_without pcre_jit # PCRE JIT -%bcond_without pdo # without PDO extension module -%bcond_without pdo_dblib # without PDO dblib extension module -%bcond_without pdo_firebird # without PDO Firebird extension module -%bcond_without pdo_mysql # without PDO MySQL extension module -%bcond_without pdo_oci # without PDO oci extension module -%bcond_without pdo_odbc # without PDO ODBC extension module -%bcond_without pdo_pgsql # without PDO pgsql extension module -%bcond_without pdo_sqlite # without PDO SQLite extension module -%bcond_without pgsql # without PostgreSQL extension module -%bcond_without phar # without Phar extension module -%bcond_without posix # without POSIX extension module -%bcond_without pspell # without pspell extension module -%bcond_without readline # without readline extension module -%bcond_without session # without session extension module -%bcond_without snmp # without SNMP extension module -%bcond_without sodium # without sodium extension module -%bcond_without sqlite2 # without SQLite extension module -%bcond_without sqlite3 # without SQLite3 extension module -%bcond_without tidy # without Tidy extension module -%bcond_without xsl # without xsl extension module -%bcond_without zip # without zip extension module +%bcond_without pdo # PDO extension module +%bcond_without pdo_dblib # PDO dblib extension module +%bcond_without pdo_firebird # PDO Firebird extension module +%bcond_without pdo_mysql # PDO MySQL extension module +%bcond_without pdo_odbc # PDO ODBC extension module +%bcond_without pdo_pgsql # PDO pgsql extension module +%bcond_without pdo_sqlite # PDO SQLite extension module +%bcond_without pgsql # PostgreSQL extension module +%bcond_without phar # Phar extension module +%bcond_without posix # POSIX extension module +%bcond_without readline # readline extension module +%bcond_without session # session extension module +%bcond_without snmp # SNMP extension module +%bcond_without sodium # sodium extension module +%bcond_without sqlite2 # SQLite extension module +%bcond_without sqlite3 # SQLite3 extension module +%bcond_without tidy # Tidy extension module +%bcond_without xsl # xsl extension module +%bcond_without zip # zip extension module # extensions options %bcond_without argon2 # argon2 password hashing -%bcond_without instantclient # build Oracle oci8 extension module against oracle-instantclient package %bcond_with interbase_inst # use InterBase install., not Firebird (BR: proprietary libs) -%bcond_with mm # without mm support for session storage +%bcond_with mm # mm support for session storage %bcond_without system_gd # system gd -%bcond_with avif # Without AVIF support in GD extension (imagecreatefromavif and imageavif) -%bcond_without webp # Without WebP support in GD extension (imagecreatefromwebp) +%bcond_with avif # AVIF support in GD extension (imagecreatefromavif and imageavif) +%bcond_without webp # WebP support in GD extension (imagecreatefromwebp) %define apxs2 /usr/sbin/apxs @@ -96,10 +90,6 @@ %undefine with_pdo_pgsql %endif -%if %{without oci} -%undefine with_pdo_oci -%endif - %ifnarch %{ix86} %{x8664} x32 # unsupported, see sapi/cgi/fpm/fpm_atomic.h %undefine with_fpm @@ -109,14 +99,13 @@ %undefine with_pdo_dblib %undefine with_pdo_firebird %undefine with_pdo_mysql -%undefine with_pdo_oci %undefine with_pdo_odbc %undefine with_pdo_pgsql %undefine with_pdo_sqlite %endif %define orgname php -%define php_suffix 83 +%define php_suffix 84 Summary: PHP: Hypertext Preprocessor Summary(fr.UTF-8): Le langage de script embarque-HTML PHP Summary(pl.UTF-8): Język skryptowy PHP @@ -124,7 +113,7 @@ Summary(pt_BR.UTF-8): A linguagem de script PHP Summary(ru.UTF-8): PHP - язык препроцессирования HTML-файлов, выполняемый на сервере Summary(uk.UTF-8): PHP - мова препроцесування HTML-файлів, виконувана на сервері Name: %{orgname}%{php_suffix} -Version: 8.3.14 +Version: 8.4.1 Release: 1 Epoch: 4 # All files licensed under PHP version 3.01, except @@ -133,7 +122,7 @@ Epoch: 4 License: PHP 3.01 and Zend and BSD Group: Libraries Source0: https://php.net/distributions/%{orgname}-%{version}.tar.xz -# Source0-md5: 875b31ca3db480fa87d19fe6651b07ad +# Source0-md5: 9ac29cee258312cd969de2a2fb307aed Source1: opcache.ini Source2: %{orgname}-mod_php.conf Source3: %{orgname}-cgi-fcgi.ini @@ -169,7 +158,6 @@ Patch44: %{orgname}-include_path.patch Patch50: extension-shared-optional-dep.patch Patch53: fix-test-run.patch Patch59: %{orgname}-systzdata.patch -Patch60: %{orgname}-oracle-instantclient.patch Patch66: php-db.patch Patch67: mysql-lib-ver-mismatch.patch # https://bugs.php.net/bug.php?id=68344 @@ -177,7 +165,6 @@ Patch68: php-mysql-ssl-context.patch Patch71: libdb-info.patch URL: http://php.net/ %{?with_pdo_firebird:%{!?with_interbase_inst:BuildRequires: Firebird-devel >= 1.0.2.908-2}} -%{?with_pspell:BuildRequires: aspell-devel >= 2:0.50.0} BuildRequires: autoconf >= 2.59 BuildRequires: automake >= 1.4d BuildRequires: bison >= 3.0.0 @@ -196,8 +183,6 @@ BuildRequires: gd-devel >= 2.1 %endif BuildRequires: gdbm-devel BuildRequires: gmp-devel >= 4.2 -%{?with_kerberos5:BuildRequires: heimdal-devel} -%{?with_imap:BuildRequires: imap-devel >= 1:2007e-2} %{?with_gcov:BuildRequires: lcov} %{?with_fpm:BuildRequires: libapparmor-devel} %{?with_argon2:BuildRequires: libargon2-devel >= 20161029} @@ -224,7 +209,6 @@ BuildRequires: oniguruma-devel %if %{with openssl} || %{with ldap} BuildRequires: openssl-devel >= 1.0.2 %endif -%{?with_oci:%{?with_instantclient:BuildRequires: oracle-instantclient-devel}} BuildRequires: pam-devel BuildRequires: pcre2-8-devel >= 10.30 BuildRequires: pkgconfig @@ -257,10 +241,10 @@ BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %define _sysconfdir %{php_sysconfdir} # must be in sync with source. extra check ensuring that it is so is done in %%build -%define php_api_version 20230831 -%define zend_module_api 20230831 -%define zend_extension_api 420230831 -%define php_pdo_api_version 20170320 +%define php_api_version 20240924 +%define zend_module_api 20240924 +%define zend_extension_api 420240924 +%define php_pdo_api_version 20240423 # Extension versions %define bz2ver %{version} @@ -271,7 +255,7 @@ BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %define jsonver %{version} %define pharver %{version} %define sqlite3ver %{version} -%define zipver 1.22.3 +%define zipver 1.22.4 %define phpdbgver %{version} %define sodiumver %{version} @@ -282,11 +266,6 @@ BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %undefine with_ccache %endif -%if %{with oci} -# ORACLE_HOME is required for oci8 ext to build -%define _preserve_env %_preserve_env_base ORACLE_HOME -%endif - %description PHP is an HTML-embedded scripting language. PHP attempts to make it easy for developers to write dynamically generated web pages. PHP also @@ -940,28 +919,6 @@ support. %description iconv -l pl.UTF-8 Moduł PHP dodający obsługę iconv. -%package imap -Summary: IMAP extension module for PHP -Summary(pl.UTF-8): Moduł IMAP dla PHP -Summary(pt_BR.UTF-8): Um módulo para aplicações PHP que usam IMAP -Group: Libraries -URL: http://php.net/manual/en/book.imap.php -Requires: %{name}-common = %{epoch}:%{version}-%{release} -Requires: %{name}-pcre = %{epoch}:%{version}-%{release} -Requires: imap-lib >= 1:2007e-2 -Provides: php(imap) -Obsoletes: php-imap < 4:5.3.28-7 - -%description imap -This is a dynamic shared object (DSO) for PHP that will add IMAP -support. - -%description imap -l pl.UTF-8 -Moduł PHP dodający obsługę skrzynek IMAP. - -%description imap -l pt_BR.UTF-8 -Um módulo para aplicações PHP que usam IMAP. - %package intl Summary: Internationalization extension (ICU wrapper) Summary(pl.UTF-8): Rozszerzenie do internacjonalizacji (interfejs do ICU) @@ -1080,25 +1037,6 @@ Przykładem tego może być fakt, że w przypadku biblioteki klienckiej każdy wiersz jest przechowywany w pamięci dwukrotnie, natomiast przy tym sterowniku - tylko raz. -%package oci8 -Summary: Oracle 8+ database module for PHP -Summary(pl.UTF-8): Moduł bazy danych Oracle 8+ dla PHP -Group: Libraries -URL: http://php.net/manual/en/book.oci8.php -%{?requires_php_extension} -Provides: php(oci8) -Obsoletes: php-oci8 < 4:5.3.28-7 -# withdrawn module of similar functionality but different API -Obsoletes: php-oracle < 4:5.1.0 - -%description oci8 -This is a dynamic shared object (DSO) for PHP that will add Oracle 7, -8, 9 and 10 database support through Oracle8 Call-Interface (OCI8). - -%description oci8 -l pl.UTF-8 -Moduł PHP umożliwiający dostęp do bazy danych Oracle 7, 8, 9 i 10 -poprzez interfejs Oracle8 Call-Interface (OCI8). - %package odbc Summary: ODBC extension module for PHP Summary(pl.UTF-8): Moduł ODBC dla PHP @@ -1257,26 +1195,6 @@ support. Moduł dla PHP dodający obsługę baz danych MySQL za pośrednictwem interfejsu PDO. -%package pdo-oci -Summary: PHP Data Objects (PDO) Oracle support -Summary(pl.UTF-8): Moduł PHP Data Objects (PDO) z obsługą Oracle'a -Group: Libraries -URL: http://php.net/manual/en/ref.pdo-oci.php -%{?requires_php_extension} -%{?requires_php_pdo_module} -Provides: php(pdo-oci) -Provides: php(pdo_oci) -Obsoletes: php-pdo-oci < 4:5.3.28-7 -Obsoletes: php-pecl-PDO_OCI - -%description pdo-oci -This is a dynamic shared object (DSO) for PHP that will add PDO Oracle -support. - -%description pdo-oci -l pl.UTF-8 -Moduł dla PHP dodający obsługę baz danych Oracle za pośrednictwem -interfejsu PDO. - %package pdo-odbc Summary: PHP Data Objects (PDO) ODBC support Summary(pl.UTF-8): Moduł PHP Data Objects (PDO) z obsługą ODBC @@ -1396,24 +1314,6 @@ functions support to PHP. %description posix -l pl.UTF-8 Moduł PHP umożliwiający korzystanie z funkcji POSIX. -%package pspell -Summary: pspell extension module for PHP -Summary(pl.UTF-8): Moduł pspell dla PHP -Group: Libraries -URL: http://php.net/manual/en/book.pspell.php -Requires: %{name}-common = %{epoch}:%{version}-%{release} -Provides: php(pspell) -Obsoletes: php-pspell < 4:5.3.28-7 - -%description pspell -This is a dynamic shared object (DSO) for PHP that will add pspell -support to PHP. It allows to check the spelling of a word and offer -suggestions. - -%description pspell -l pl.UTF-8 -Moduł PHP umożliwiający korzystanie z pspella. Pozwala on na -sprawdzanie pisowni słowa i sugerowanie poprawek. - %package readline Summary: readline extension module for PHP Summary(pl.UTF-8): Moduł readline dla PHP @@ -1811,9 +1711,6 @@ cp -p php.ini-production php.ini %patch50 -p1 %patch53 -p1 %patch59 -p1 -%if %{with instantclient} -%patch60 -p1 -%endif %patch66 -p1 %patch67 -p1 #%patch68 -p1 DROP or update to 7.0 APIs @@ -2080,8 +1977,7 @@ for sapi in $sapis; do sapi_args='--enable-embed' ;; apxs2) - ver=$(rpm -q --qf '%{V}' apache-devel) - sapi_args="--with-apxs2=%{apxs2} --with-apache-version=$ver" + sapi_args="--with-apxs2=%{apxs2}" ;; litespeed) sapi_args='--enable-litespeed' @@ -2112,6 +2008,7 @@ for sapi in $sapis; do --enable-option-checking=fatal \ %{__enable_disable bcmath bcmath shared} \ %{__enable_disable calendar calendar shared} \ + %{?with_opcache:--with-capstone} \ %{__enable_disable ctype ctype shared} \ %{__enable_disable dba dba shared} \ %{__enable_disable dom dom shared} \ @@ -2140,7 +2037,6 @@ for sapi in $sapis; do %{?with_mhash:--with-mhash=yes} \ --with-mysql-sock=/var/lib/mysql/mysql.sock \ %{__with_without pdo_mysql pdo-mysql shared,%{!?with_mysqlnd:/usr}%{?with_mysqlnd:mysqlnd}} \ - %{?with_pdo_oci:--with-pdo-oci=shared%{?with_instantclient:,instantclient,%{_libdir}}} \ %{?with_pdo_odbc:--with-pdo-odbc=shared,unixODBC,/usr} \ %{?with_pdo_pgsql:--with-pdo-pgsql=shared} \ %{?with_pdo_sqlite:--with-pdo-sqlite=shared} \ @@ -2171,23 +2067,19 @@ for sapi in $sapis; do --with-gdbm \ %{__with_without gmp gmp shared} \ %{__with_without ffi ffi shared} \ - %{?with_imap:--with-imap=shared --with-imap-ssl} \ --with-jpeg \ %{?with_ldap:--with-ldap=shared --with-ldap-sasl} \ %{?with_mm:--with-mm} \ %{?with_mysqlnd:--enable-mysqlnd=shared} \ %{?with_mysqli:--with-mysqli=shared,%{!?with_mysqlnd:/usr/bin/mysql_config}%{?with_mysqlnd:mysqlnd}} \ - %{?with_oci:--with-oci8=shared%{?with_instantclient:,instantclient,%{_libdir}}} \ %{__enable_disable opcache opcache shared} \ %{?with_openssl:--with-openssl=shared} \ - %{?with_kerberos5:--with-kerberos} \ --with-tcadb=/usr \ --with-external-pcre \ %{__with_without pcre_jit pcre-jit} \ %{__enable_disable filter filter shared} \ %{__with_without pgsql pgsql shared} \ %{__enable_disable phar phar shared} \ - %{?with_pspell:--with-pspell=shared} \ %{__with_without readline readline shared} \ %{?with_snmp:--with-snmp=shared} \ %{!?with_pdo_sqlite:--without-pdo-sqlite} \ @@ -2609,13 +2501,11 @@ fi \ %extension_scripts gettext %extension_scripts gmp %extension_scripts iconv -%extension_scripts imap %extension_scripts intl %extension_scripts ldap %extension_scripts mbstring %extension_scripts mysqli %extension_scripts mysqlnd -%extension_scripts oci8 %extension_scripts odbc %extension_scripts opcache %extension_scripts openssl @@ -2624,13 +2514,11 @@ fi \ %extension_scripts pdo-dblib %extension_scripts pdo-firebird %extension_scripts pdo-mysql -%extension_scripts pdo-oci %extension_scripts pdo-odbc %extension_scripts pdo-pgsql %extension_scripts pdo-sqlite %extension_scripts pgsql %extension_scripts posix -%extension_scripts pspell %extension_scripts session %extension_scripts shmop %extension_scripts simplexml @@ -2891,14 +2779,6 @@ fi %attr(755,root,root) %{php_extensiondir}/iconv.so %endif -%if %{with imap} -%files imap -%defattr(644,root,root,755) -%doc ext/imap/CREDITS -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/??_imap.ini -%attr(755,root,root) %{php_extensiondir}/imap.so -%endif - %if %{with intl} %files intl %defattr(644,root,root,755) @@ -2939,14 +2819,6 @@ fi %attr(755,root,root) %{php_extensiondir}/mysqlnd.so %endif -%if %{with pdo_oci} -%files oci8 -%defattr(644,root,root,755) -%doc ext/oci8/{CREDITS,README} -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/??_oci8.ini -%attr(755,root,root) %{php_extensiondir}/oci8.so -%endif - %if %{with odbc} %files odbc %defattr(644,root,root,755) @@ -3011,14 +2883,6 @@ fi %attr(755,root,root) %{php_extensiondir}/pdo_mysql.so %endif -%if %{with oci} -%files pdo-oci -%defattr(644,root,root,755) -%doc ext/pdo_oci/CREDITS -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/??_pdo_oci.ini -%attr(755,root,root) %{php_extensiondir}/pdo_oci.so -%endif - %if %{with pdo_odbc} %files pdo-odbc %defattr(644,root,root,755) @@ -3071,13 +2935,6 @@ fi %attr(755,root,root) %{php_extensiondir}/posix.so %endif -%if %{with pspell} -%files pspell -%defattr(644,root,root,755) -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/??_pspell.ini -%attr(755,root,root) %{php_extensiondir}/pspell.so -%endif - %if %{with readline} %files readline %defattr(644,root,root,755) -- 2.49.0