summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoe George <joe@zeroc.com>2017-12-04 15:17:59 -0500
committerJoe George <joe@zeroc.com>2017-12-04 15:17:59 -0500
commitec6eefc08592c2da5f46e7f7d55fe7ca725a0bd7 (patch)
treed4c0450ffa8025de3098ec89999cc9c415c772aa
parentICE-8378 - cloneWithPrefix cause System.IO.IOException: with IceBox and Ice.F... (diff)
downloadice-3.7.0-php53.tar.bz2
ice-3.7.0-php53.tar.xz
ice-3.7.0-php53.zip
Fix ICE-8579 - PHP 5.3 build failure with GCC 6v3.7.0-php53
-rw-r--r--php/config/Make.rules6
1 files changed, 6 insertions, 0 deletions
diff --git a/php/config/Make.rules b/php/config/Make.rules
index 58151d746ee..a19cd306d87 100644
--- a/php/config/Make.rules
+++ b/php/config/Make.rules
@@ -31,6 +31,12 @@ else
php_cppflags := $(php_cppflags) -DICEPHP_USE_NAMESPACES
endif
+# PHP 5.3 does not compile with C++11 due to an issue with
+# user defined literals. PHP 5.4 and up do not have this issue.
+ifeq ($(shell [ $$($(PHP_CONFIG) --vernum) -lt 50400 ] && echo 0),0)
+ php_cppflags := -std=c++98 $(php_cppflags)
+endif
+
ifeq ($(os),Darwin)
php_ldflags := ${wl}-flat_namespace ${wl}-undefined ${wl}suppress
endif