Skip to content

Commit da0a0a1

Browse files
committed
Fixed bug #79946
Declare __STDC_CONSTANT_MACROS and __STDC_FORMAT_MACROS via -D to make sure they are declared before the first stdint.h include. We also define these in php_stdint.h, but don't always include that file first. This is necessary for old compilers that use C99 rather than C11 semantics for stdint.h.
1 parent cedf463 commit da0a0a1

File tree

3 files changed

+2
-2
lines changed

3 files changed

+2
-2
lines changed

NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ PHP NEWS
1212
in the stack trace). (Nikita)
1313
. Fixed bug #79897 (Promoted constructor params with attribs cause crash).
1414
(Deus Kane)
15+
. Fixed bug #79946 (Build fails due to undeclared UINT32_C). (Nikita)
1516

1617
- Date:
1718
. Fixed bug #60302 (DateTime::createFromFormat should new static(), not new

ext/intl/calendar/calendar_methods.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include "config.h"
1717
#endif
1818

19-
#define __STDC_FORMAT_MACROS
2019
#include <inttypes.h>
2120

2221
#include "../intl_cppshims.h"

ext/intl/config.m4

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ PHP_ARG_ENABLE([intl],
66
if test "$PHP_INTL" != "no"; then
77
PHP_SETUP_ICU(INTL_SHARED_LIBADD)
88
PHP_SUBST(INTL_SHARED_LIBADD)
9-
INTL_COMMON_FLAGS="$ICU_CFLAGS -Wno-write-strings -D__STDC_LIMIT_MACROS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
9+
INTL_COMMON_FLAGS="$ICU_CFLAGS -Wno-write-strings -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
1010
PHP_NEW_EXTENSION(intl, php_intl.c \
1111
intl_error.c \
1212
intl_convert.c \

0 commit comments

Comments
 (0)