Merge pull request #119126 from fabaff/pycomfoconnect
[NixPkgs.git] / pkgs / development / interpreters / php / php73-darwin-isfinite.patch
blob7f784e0f5a95cf77681d72bf6d14d0fdc967185b
1 diff -ru a/configure.ac b/configure.ac
2 --- a/configure.ac 2018-12-04 19:12:20.000000000 +0300
3 +++ b/configure.ac 2018-12-10 12:30:37.798917520 +0300
4 @@ -68,7 +68,7 @@
5 #include <math.h>
7 #ifndef zend_isnan
8 -#if HAVE_DECL_ISNAN && (!defined(__cplusplus) || __cplusplus < 201103L)
9 +#if HAVE_DECL_ISNAN && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
10 #define zend_isnan(a) isnan(a)
11 #elif defined(HAVE_FPCLASS)
12 #define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN))
13 @@ -77,7 +77,7 @@
14 #endif
15 #endif
17 -#if HAVE_DECL_ISINF && (!defined(__cplusplus) || __cplusplus < 201103L)
18 +#if HAVE_DECL_ISINF && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
19 #define zend_isinf(a) isinf(a)
20 #elif defined(INFINITY)
21 /* Might not work, but is required by ISO C99 */
22 @@ -88,7 +88,7 @@
23 #define zend_isinf(a) 0
24 #endif
26 -#if HAVE_DECL_ISFINITE && (!defined(__cplusplus) || __cplusplus < 201103L)
27 +#if HAVE_DECL_ISFINITE && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
28 #define zend_finite(a) isfinite(a)
29 #elif defined(HAVE_FINITE)
30 #define zend_finite(a) finite(a)
31 diff -ru a/Zend/configure.ac b/Zend/configure.ac
32 --- a/Zend/configure.ac 2018-12-04 19:12:30.000000000 +0300
33 +++ b/Zend/configure.ac 2018-12-10 12:28:50.350929699 +0300
34 @@ -59,7 +59,7 @@
35 #include <math.h>
37 #ifndef zend_isnan
38 -#if HAVE_DECL_ISNAN && (!defined(__cplusplus) || __cplusplus < 201103L)
39 +#if HAVE_DECL_ISNAN && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
40 #define zend_isnan(a) isnan(a)
41 #elif defined(HAVE_FPCLASS)
42 #define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN))
43 @@ -68,7 +68,7 @@
44 #endif
45 #endif
47 -#if HAVE_DECL_ISINF && (!defined(__cplusplus) || __cplusplus < 201103L)
48 +#if HAVE_DECL_ISINF && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
49 #define zend_isinf(a) isinf(a)
50 #elif defined(INFINITY)
51 /* Might not work, but is required by ISO C99 */
52 @@ -79,7 +79,7 @@
53 #define zend_isinf(a) 0
54 #endif
56 -#if HAVE_DECL_ISFINITE && (!defined(__cplusplus) || __cplusplus < 201103L)
57 +#if HAVE_DECL_ISFINITE && (defined(__APPLE__) || defined(__APPLE_CC__) || !defined(__cplusplus) || __cplusplus < 201103L)
58 #define zend_finite(a) isfinite(a)
59 #elif defined(HAVE_FINITE)
60 #define zend_finite(a) finite(a)