summaryrefslogtreecommitdiffstats
path: root/package/php/0007-avoid-bfin-gcc-segfault.patch
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2016-11-09 08:05:31 +0100
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-11-09 22:05:40 +0100
commit6668a0ed5ce5174d2307997e7a6d7c9f94ccb282 (patch)
tree0396fdaf4b77de9d884ef40b4f7f03aaaadc64be /package/php/0007-avoid-bfin-gcc-segfault.patch
parent7be691623a27087cc89c169e21466a0e66a75eb4 (diff)
downloadbuildroot-6668a0ed5ce5174d2307997e7a6d7c9f94ccb282.tar.gz
buildroot-6668a0ed5ce5174d2307997e7a6d7c9f94ccb282.zip
php: fix bfin compile issue
Fixes: http://autobuild.buildroot.net/results/8326f24511d3b109d22a76660adc017bbcaca197 Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/php/0007-avoid-bfin-gcc-segfault.patch')
-rw-r--r--package/php/0007-avoid-bfin-gcc-segfault.patch16
1 files changed, 16 insertions, 0 deletions
diff --git a/package/php/0007-avoid-bfin-gcc-segfault.patch b/package/php/0007-avoid-bfin-gcc-segfault.patch
new file mode 100644
index 0000000000..4dccb25f1f
--- /dev/null
+++ b/package/php/0007-avoid-bfin-gcc-segfault.patch
@@ -0,0 +1,16 @@
+Avoid gcc segmentation fault
+
+Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
+
+diff -Nur php-7.0.12.orig/Zend/zend_portability.h php-7.0.12/Zend/zend_portability.h
+--- php-7.0.12.orig/Zend/zend_portability.h 2016-10-13 16:04:17.000000000 +0200
++++ php-7.0.12/Zend/zend_portability.h 2016-11-08 02:49:39.118388999 +0100
+@@ -97,7 +97,7 @@
+
+ #if defined(ZEND_WIN32) && !defined(__clang__)
+ # define ZEND_ASSUME(c) __assume(c)
+-#elif ((defined(__GNUC__) && ZEND_GCC_VERSION >= 4005) || __has_builtin(__builtin_unreachable)) && PHP_HAVE_BUILTIN_EXPECT
++#elif ((defined(__GNUC__) && ZEND_GCC_VERSION >= 4005) || __has_builtin(__builtin_unreachable)) && PHP_HAVE_BUILTIN_EXPECT && !defined(__bfin__)
+ # define ZEND_ASSUME(c) do { \
+ if (__builtin_expect(!(c), 0)) __builtin_unreachable(); \
+ } while (0)
OpenPOWER on IntegriCloud