Edit report at https://bugs.php.net/bug.php?id=76826&edit=1
ID: 76826
User updated by: php-bugs-2018 at ryandesign dot com
Reported by: php-bugs-2018 at ryandesign dot com
Summary: error: use of undeclared identifier 'finite'
-Status: Feedback
+Status: Open
Type: Bug
Package: Compile Failure
Operating System: Mac OS X 10.7.5
PHP Version: 7.2.9
Block user comment: N
Private report: N
New Comment:
I do use phpize from the same version of PHP. I know that intl can be built as a separate extension
using phpize; we do so in MacPorts. This bug report is that on this specific version of Mac OS X
with its version of Xcode, and this version of PHP, it fails to compile. It's not a problem
with older versions of PHP on this version of Mac OS X and Xcode, and it's not a problem with
this version of PHP on other versions of Mac OS X and Xcode.
Both on Mac OS X 10.7 where the build fails, and on 10.8 and later up to at least 10.13 where the
build succeeds, __cplusplus is 199711L. On Mac OS X 10.6 where the build also succeeds, the Apple
gcc 4.2.1 compiler is used, and its __cplusplus value is 1.
Previous Comments:
------------------------------------------------------------------------
[2018-09-03 12:53:36] ab@php.net
Thanks for the report. Perhaps you need to use phpize from the same (or at least) PHP version. Older
PHP versions will have different php_config.h. Otherwise, ext/intl can also be built shared.
Btw, what does __cplusplus macro contain?
Thanks.
------------------------------------------------------------------------
[2018-08-31 04:11:25] php-bugs-2018 at ryandesign dot com
Description:
------------
Building the bundled intl extension (I happen to build it separately from php, using phpize) fails
on Mac OS X 10.7.5 (with clang 425.0.28 as provided by Xcode 4.6.3), in several PHP versions (7.2.9,
7.1.21). It worked in previous PHP versions. Here's the error message from PHP 7.2.9:
In file included from ext/intl/intl_convertcpp.cpp:24:
In file included from /opt/local/include/php72/php/main/php.h:35:
In file included from /opt/local/include/php72/php/Zend/zend.h:328:
/opt/local/include/php72/php/Zend/zend_operators.h:114:18: error: use of undeclared identifier
'finite'
if (UNEXPECTED(!zend_finite(d)) || UNEXPECTED(zend_isnan(d))) {
^
/opt/local/include/php72/php/main/../main/php_config.h:2619:24: note: expanded from macro
'zend_finite'
#define zend_finite(a) finite(a)
^
/opt/local/include/php72/php/Zend/zend_portability.h:312:52: note: expanded from macro
'UNEXPECTED'
# define UNEXPECTED(condition) __builtin_expect(!!(condition), 0)
^
Perhaps it was caused by this commit: https://github.com/php/php-src/commit/ad790bea2e4a8a25c79ceab964601f3785cd2bf1
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=76826&edit=1