diff options
author | Remi Collet <remi@remirepo.net> | 2017-09-13 10:29:16 +0200 |
---|---|---|
committer | Remi Collet <remi@remirepo.net> | 2017-09-13 10:29:16 +0200 |
commit | 9e4e014cc45d8275382f33c0a532a0afa4811ed3 (patch) | |
tree | 5243a2fdd786195db380f705535a3ce60c80623f | |
parent | 6518fb698394e71407c14e99102ea4ce6df1d664 (diff) |
Update to 7.1.10RC1
Automatically load OpenSSL configuration file, from PHP 7.2
-rw-r--r-- | 2750.patch | 51 | ||||
-rw-r--r-- | failed.txt | 6 | ||||
-rw-r--r-- | php-7.1.7-httpd.patch | 28 | ||||
-rw-r--r-- | php-7.1.9-openssl-load-config.patch | 52 | ||||
-rw-r--r-- | php-upstream.patch | 42 | ||||
-rw-r--r-- | php.spec | 15 |
6 files changed, 108 insertions, 86 deletions
diff --git a/2750.patch b/2750.patch deleted file mode 100644 index 6eb4e0f..0000000 --- a/2750.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 8b55da74170b0c8686d2f2fa3d4e858f7785b6a2 Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@remirepo.net> -Date: Tue, 12 Sep 2017 09:16:24 +0200 -Subject: [PATCH] Fixed bug #75193 segfault in - collator_convert_object_to_string - ---- - ext/intl/collator/collator_sort.c | 8 ++++++-- - ext/intl/tests/bug75193.phpt | 14 ++++++++++++++ - 2 files changed, 20 insertions(+), 2 deletions(-) - create mode 100644 ext/intl/tests/bug75193.phpt - -diff --git a/ext/intl/collator/collator_sort.c b/ext/intl/collator/collator_sort.c -index 1ad42d3660f0..7e7bde671f6b 100644 ---- a/ext/intl/collator/collator_sort.c -+++ b/ext/intl/collator/collator_sort.c -@@ -59,8 +59,12 @@ static int collator_regular_compare_function(zval *result, zval *op1, zval *op2) - zval norm1, norm2; - zval *num1_p = NULL, *num2_p = NULL; - zval *norm1_p = NULL, *norm2_p = NULL; -- zval* str1_p = collator_convert_object_to_string( op1, &str1 ); -- zval* str2_p = collator_convert_object_to_string( op2, &str2 ); -+ zval *str1_p, *str2_p; -+ -+ ZVAL_NULL(&str1); -+ str1_p = collator_convert_object_to_string( op1, &str1 ); -+ ZVAL_NULL(&str2); -+ str2_p = collator_convert_object_to_string( op2, &str2 ); - - /* If both args are strings AND either of args is not numeric string - * then use ICU-compare. Otherwise PHP-compare. */ -diff --git a/ext/intl/tests/bug75193.phpt b/ext/intl/tests/bug75193.phpt -new file mode 100644 -index 000000000000..d6c32dbe260a ---- /dev/null -+++ b/ext/intl/tests/bug75193.phpt -@@ -0,0 +1,14 @@ -+--TEST-- -+Bug #75193 segfault in collator_convert_object_to_string -+--SKIPIF-- -+<?php if( !extension_loaded( 'intl' ) ) print 'skip'; ?> -+--FILE-- -+<?php -+$a = new \Collator('en_US'); -+$b = [new stdclass, new stdclass]; -+var_dump($a->sort($b)); -+?> -+===DONE=== -+--EXPECT-- -+bool(true) -+===DONE=== @@ -1,4 +1,4 @@ -===== 7.1.9 (2017-08-31) +===== 7.1.10RC1 (2017-09-14) $ grep -r 'Tests failed' /var/lib/mock/scl71*/build.log @@ -8,11 +8,9 @@ $ grep -r 'Tests failed' /var/lib/mock/scl71*/build.log /var/lib/mock/scl70fc24x/build.log:Tests failed : 0 /var/lib/mock/scl70fc25x/build.log:Tests failed : 0 /var/lib/mock/scl70fc26x/build.log:Tests failed : 0 -/var/lib/mock/scl70fc27x/build.log:Tests failed : 1 +/var/lib/mock/scl70fc27x/build.log:Tests failed : 0 -fc27x - 2 substr_compare() [ext/standard/tests/strings/substr_compare.phpt] 1 proc_open give erratic test results :( diff --git a/php-7.1.7-httpd.patch b/php-7.1.7-httpd.patch new file mode 100644 index 0000000..acb3d2c --- /dev/null +++ b/php-7.1.7-httpd.patch @@ -0,0 +1,28 @@ +Disable MPM detection + +mod_php is build twice +- as NTS without option +- as ZTS using --enable-maintainer-zts + +diff --git a/sapi/apache2handler/config.m4 b/sapi/apache2handler/config.m4 +index 2e64b21..ec4799f 100644 +--- a/sapi/apache2handler/config.m4 ++++ b/sapi/apache2handler/config.m4 +@@ -116,17 +116,6 @@ if test "$PHP_APXS2" != "no"; then + ;; + esac + +- if test "$APACHE_VERSION" -lt 2004001; then +- APXS_MPM=`$APXS -q MPM_NAME` +- if test "$APXS_MPM" != "prefork" && test "$APXS_MPM" != "peruser" && test "$APXS_MPM" != "itk"; then +- PHP_BUILD_THREAD_SAFE +- fi +- else +- APACHE_THREADED_MPM=`$APXS_HTTPD -V | grep 'threaded:.*yes'` +- if test -n "$APACHE_THREADED_MPM"; then +- PHP_BUILD_THREAD_SAFE +- fi +- fi + AC_MSG_RESULT(yes) + PHP_SUBST(APXS) + else diff --git a/php-7.1.9-openssl-load-config.patch b/php-7.1.9-openssl-load-config.patch new file mode 100644 index 0000000..c998667 --- /dev/null +++ b/php-7.1.9-openssl-load-config.patch @@ -0,0 +1,52 @@ +Backported from PHP 7.2 + + +From 58df6a3b61f5cb914d899fbb44eecadad8098700 Mon Sep 17 00:00:00 2001 +From: Jakub Zelenka <bukka@php.net> +Date: Mon, 28 Aug 2017 18:48:25 +0100 +Subject: [PATCH] Do not explicitly initialize and clean up OpenSSL for OpenSSL + 1.1 + +From 1f843a8fb50de77a3f53a6b892a46d9e0afdfdd7 Mon Sep 17 00:00:00 2001 +From: Jakub Zelenka <bukka@php.net> +Date: Mon, 28 Aug 2017 19:25:18 +0100 +Subject: [PATCH] Automatically load OpenSSL configuration file + +diff -up ./ext/openssl/openssl.c.loadconf ./ext/openssl/openssl.c +--- ./ext/openssl/openssl.c.loadconf 2017-08-30 18:13:18.000000000 +0200 ++++ ./ext/openssl/openssl.c 2017-09-06 13:11:47.212803443 +0200 +@@ -1409,6 +1409,8 @@ PHP_MINIT_FUNCTION(openssl) + le_x509 = zend_register_list_destructors_ex(php_x509_free, NULL, "OpenSSL X.509", module_number); + le_csr = zend_register_list_destructors_ex(php_csr_free, NULL, "OpenSSL X.509 CSR", module_number); + ++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined (LIBRESSL_VERSION_NUMBER) ++ OPENSSL_config(NULL); + SSL_library_init(); + OpenSSL_add_all_ciphers(); + OpenSSL_add_all_digests(); +@@ -1421,6 +1423,9 @@ PHP_MINIT_FUNCTION(openssl) + #endif + + SSL_load_error_strings(); ++#else ++ OPENSSL_init_ssl(OPENSSL_INIT_LOAD_CONFIG, NULL); ++#endif + + /* register a resource id number with OpenSSL so that we can map SSL -> stream structures in + * OpenSSL callbacks */ +@@ -1585,12 +1590,15 @@ PHP_MINFO_FUNCTION(openssl) + */ + PHP_MSHUTDOWN_FUNCTION(openssl) + { ++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined (LIBRESSL_VERSION_NUMBER) + EVP_cleanup(); + + /* prevent accessing locking callback from unloaded extension */ + CRYPTO_set_locking_callback(NULL); + /* free allocated error strings */ + ERR_free_strings(); ++ CONF_modules_free(); ++#endif + + php_unregister_url_stream_wrapper("https"); + php_unregister_url_stream_wrapper("ftps"); diff --git a/php-upstream.patch b/php-upstream.patch index 448fd7c..84862e9 100644 --- a/php-upstream.patch +++ b/php-upstream.patch @@ -1,30 +1,20 @@ -From 3239f6d6798d86fdbf8e03aa741d9990bcfffe79 Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@php.net> -Date: Thu, 31 Aug 2017 07:55:45 +0200 -Subject: [PATCH] move AC_DEFINE in the right position (in bundled lib - conditon) +From 7674b5e5749e8c0076357167ca553f153c94e6d1 Mon Sep 17 00:00:00 2001 +From: Anatol Belski <ab@php.net> +Date: Tue, 12 Sep 2017 18:17:28 +0200 +Subject: [PATCH] Fix test failure on 32-bit --- - ext/sqlite3/config0.m4 | 2 +- + ext/standard/tests/serialize/bug74103.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/ext/sqlite3/config0.m4 b/ext/sqlite3/config0.m4 -index 0e5fbc5..78fd622 100644 ---- a/ext/sqlite3/config0.m4 -+++ b/ext/sqlite3/config0.m4 -@@ -85,11 +85,11 @@ if test $PHP_SQLITE3 != "no"; then - other_flags="$other_flags -DSQLITE_ENABLE_ICU=1" - fi - -+ AC_DEFINE(HAVE_SQLITE3_ERRSTR, 1, [have sqlite3_errstr function]) - PHP_SQLITE3_CFLAGS="-I@ext_srcdir@/libsqlite $other_flags $threadsafe_flags $debug_flags" - PHP_INSTALL_HEADERS([ext/sqlite3/libsqlite/sqlite3.h]) - fi - -- AC_DEFINE(HAVE_SQLITE3_ERRSTR, 1, [have sqlite3_errstr function]) - AC_DEFINE(HAVE_SQLITE3,1,[ ]) - - sqlite3_sources="sqlite3.c $sqlite3_extra_sources" --- -2.1.4 - +diff --git a/ext/standard/tests/serialize/bug74103.phpt b/ext/standard/tests/serialize/bug74103.phpt +index 3d474b31b1cd..97076ffe466e 100644 +--- a/ext/standard/tests/serialize/bug74103.phpt ++++ b/ext/standard/tests/serialize/bug74103.phpt +@@ -5,5 +5,5 @@ Bug #74103: heap-use-after-free when uns + var_dump(unserialize('a:7:{i:0;i:04;s:1:"a";i:2;i:9617006;i:4;s:1:"a";i:4;s:1:"a";R:5;s:1:"7";R:3;s:1:"a";R:5;;s:18;}}')); + ?> + --EXPECTF-- +-Notice: unserialize(): Error at offset 64 of 96 bytes in %s on line %d ++Notice: unserialize(): Error at offset %d of %d bytes in %s on line %d + bool(false) @@ -120,13 +120,13 @@ %global db_devel libdb-devel %endif -%global upver 7.1.9 -#global rcver RC1 +%global upver 7.1.10 +%global rcver RC1 Summary: PHP scripting language for creating dynamic web sites Name: %{?scl_prefix}php Version: %{upver}%{?rcver:~%{rcver}} -Release: 3%{?dist} +Release: 1%{?dist} # All files licensed under PHP version 3.01, except # Zend is licensed under Zend # TSRM is licensed under BSD @@ -176,6 +176,8 @@ Patch45: php-5.6.3-ldap_r.patch Patch46: php-7.0.0-fixheader.patch # drop "Configure command" from phpinfo output Patch47: php-5.6.3-phpinfo.patch +# Automatically load OpenSSL configuration file +Patch48: php-7.1.9-openssl-load-config.patch # RC Patch Patch91: php-5.6.3-oci8conf.patch @@ -192,7 +194,6 @@ Patch300: php-7.0.10-datetests.patch Patch301: php-7.0.0-oldpcre.patch # WIP -Patch400: 2750.patch BuildRequires: bzip2-devel, curl-devel >= 7.9, %{db_devel} BuildRequires: httpd-devel >= 2.0.46-1, pam-devel @@ -886,6 +887,7 @@ support for JavaScript Object Notation (JSON) to PHP. %endif %patch46 -p1 -b .fixheader %patch47 -p1 -b .phpinfo +%patch48 -p1 -b .loadconf %patch91 -p1 -b .remi-oci8 @@ -904,7 +906,6 @@ fi %endif # WIP patch -%patch400 -p1 -b .75193 # Prevent %%doc confusion over LICENSE files cp Zend/LICENSE Zend/ZEND_LICENSE @@ -1810,6 +1811,10 @@ fi %changelog +* Wed Sep 13 2017 Remi Collet <remi@remirepo.net> - 7.1.10~RC1-1 +- Update to 7.1.10RC1 +- Automatically load OpenSSL configuration file, from PHP 7.2 + * Tue Sep 12 2017 Remi Collet <remi@fedoraproject.org> - 7.1.9-3 - test build for https://github.com/php/php-src/pull/2750 |