summaryrefslogtreecommitdiffstats
path: root/266.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2020-04-27 10:29:11 +0200
committerRemi Collet <remi@remirepo.net>2020-04-27 10:29:11 +0200
commitb76f4dd213c626a9f0bc0ef7cacb5196d5a9e696 (patch)
tree9805005d4789308d8a83823afe9c2686627442a7 /266.patch
initial package
fix build with recent GCC using patch from https://github.com/ice/framework/pull/266
Diffstat (limited to '266.patch')
-rw-r--r--266.patch57
1 files changed, 57 insertions, 0 deletions
diff --git a/266.patch b/266.patch
new file mode 100644
index 0000000..aa160b5
--- /dev/null
+++ b/266.patch
@@ -0,0 +1,57 @@
+From f9ab74b28ce6a0add3a24c57c7c7f9f5fa1dc9d7 Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Mon, 27 Apr 2020 10:15:06 +0200
+Subject: [PATCH] fix build with recent GCC
+
+---
+ build/php7/ice.c | 9 ++++++---
+ build/php7/php_ice.h | 2 +-
+ 2 files changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/build/php7/ice.c b/build/php7/ice.c
+index 304c911d..fb0d45e2 100644
+--- a/build/php7/ice.c
++++ b/build/php7/ice.c
+@@ -21,6 +21,9 @@
+ #include "kernel/fcall.h"
+ #include "kernel/memory.h"
+
++#ifdef ZTS
++ZEND_TSRMLS_CACHE_DEFINE()
++#endif
+
+
+ zend_class_entry *ice_i18n_plural_pluralinterface_ce;
+@@ -320,9 +323,6 @@ static void php_zephir_init_module_globals(zend_ice_globals *ice_globals TSRMLS_
+ static PHP_RINIT_FUNCTION(ice)
+ {
+ zend_ice_globals *ice_globals_ptr;
+-#ifdef ZTS
+- tsrm_ls = ts_resource(0);
+-#endif
+ ice_globals_ptr = ZEPHIR_VGLOBAL;
+
+ php_zephir_init_globals(ice_globals_ptr);
+@@ -368,6 +368,9 @@ static PHP_MINFO_FUNCTION(ice)
+
+ static PHP_GINIT_FUNCTION(ice)
+ {
++#ifdef ZTS
++ ZEND_TSRMLS_CACHE_UPDATE();
++#endif
+ php_zephir_init_globals(ice_globals);
+ php_zephir_init_module_globals(ice_globals);
+ }
+diff --git a/build/php7/php_ice.h b/build/php7/php_ice.h
+index ee20ead9..20906e49 100644
+--- a/build/php7/php_ice.h
++++ b/build/php7/php_ice.h
+@@ -53,7 +53,7 @@ ZEND_EXTERN_MODULE_GLOBALS(ice)
+ #endif
+
+ #ifdef ZTS
+- void ***tsrm_ls;
++ ZEND_TSRMLS_CACHE_EXTERN()
+ #define ZEPHIR_VGLOBAL ((zend_ice_globals *) (*((void ***) tsrm_get_ls_cache()))[TSRM_UNSHUFFLE_RSRC_ID(ice_globals_id)])
+ #else
+ #define ZEPHIR_VGLOBAL &(ice_globals)