summaryrefslogtreecommitdiff
path: root/dev-lang/php/files
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2016-08-04 12:47:29 -0400
committerMichael Orlitzky <mjo@gentoo.org>2016-08-04 14:59:12 -0400
commit36626b1d255da79d9e52bbd907ec579b9efa93c5 (patch)
treed02415281c7849a3b461a04e20854cc8b072a1e2 /dev-lang/php/files
parentd5c2b1d289b7d7840ab8c16c5f90f9ed734e0e59 (diff)
downloadgentoo-36626b1d255da79d9e52bbd907ec579b9efa93c5.tar.gz
gentoo-36626b1d255da79d9e52bbd907ec579b9efa93c5.tar.bz2
gentoo-36626b1d255da79d9e52bbd907ec579b9efa93c5.zip
dev-lang/php: new 7.x revision to fix the build on x86.
There is an upstream bug that causes the build to fail on x86 with gcc-4.9. There was an earlier fix for gcc-4.8, and this new revision has a fix that also works for gcc-4.9. And, since we're no longer inheriting depend.apache.eclass, I was finally able to update the ebuild to EAPI=6. A redundant earlier ebuild for php-7.0.9 was also removed. Gentoo-Bug: 571658 Package-Manager: portage-2.2.28
Diffstat (limited to 'dev-lang/php/files')
-rw-r--r--dev-lang/php/files/fix-x86-build-bug_571658.patch51
1 files changed, 51 insertions, 0 deletions
diff --git a/dev-lang/php/files/fix-x86-build-bug_571658.patch b/dev-lang/php/files/fix-x86-build-bug_571658.patch
new file mode 100644
index 000000000000..46f68b686557
--- /dev/null
+++ b/dev-lang/php/files/fix-x86-build-bug_571658.patch
@@ -0,0 +1,51 @@
+From 2fcc388d9bf238673ed84b8f38d7753279aea48c Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky <michael@orlitzky.com>
+Date: Thu, 4 Aug 2016 11:42:56 -0400
+Subject: [PATCH 1/1] Zend/zend_operators.h: disable x86 assembly on all newer
+ GCC-4.x.
+
+In bug 69896, a fix was committed to work around a build error: 'asm'
+operand has impossible constraints, in zend_operators.h, on x86. At
+the time, the problem was only visible with gcc-4.8, and the fix was
+to disable that chunk of assembly for gcc-4.8. With gcc-4.9, the
+problem persists, so we now need to check for gcc-4.9 (at least) in
+addition to gcc-4.8.
+
+This commit modifies the earlier conditional that checks for
+gcc-4.8. The existing check was for equality on the minor component of
+the gcc version, namely 8. The == operator that performs the
+comparison has been changed to <=, so that it catches any gcc-4.x with
+x >= 8. This has been tested and fixes the build on x86 hardware with
+gcc-4.9.
+
+PHP-Bug: 69896
+Gentoo-Bug: 571658
+---
+ Zend/zend_operators.h | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h
+index 3705022..dd7c354 100644
+--- a/Zend/zend_operators.h
++++ b/Zend/zend_operators.h
+@@ -520,7 +520,7 @@ static zend_always_inline void fast_long_decrement_function(zval *op1)
+
+ static zend_always_inline void fast_long_add_function(zval *result, zval *op1, zval *op2)
+ {
+-#if defined(__GNUC__) && defined(__i386__) && !(4 == __GNUC__ && 8 == __GNUC_MINOR__)
++#if defined(__GNUC__) && defined(__i386__) && !(4 == __GNUC__ && 8 <= __GNUC_MINOR__)
+ __asm__(
+ "movl (%1), %%eax\n\t"
+ "addl (%2), %%eax\n\t"
+@@ -606,7 +606,7 @@ static zend_always_inline int fast_add_function(zval *result, zval *op1, zval *o
+
+ static zend_always_inline void fast_long_sub_function(zval *result, zval *op1, zval *op2)
+ {
+-#if defined(__GNUC__) && defined(__i386__) && !(4 == __GNUC__ && 8 == __GNUC_MINOR__)
++#if defined(__GNUC__) && defined(__i386__) && !(4 == __GNUC__ && 8 <= __GNUC_MINOR__)
+ __asm__(
+ "movl (%1), %%eax\n\t"
+ "subl (%2), %%eax\n\t"
+--
+2.7.3
+