diff --git a/Zend/zend_cpuinfo.h b/Zend/zend_cpuinfo.h index 513dacfd08f5..855e245beafe 100644 --- a/Zend/zend_cpuinfo.h +++ b/Zend/zend_cpuinfo.h @@ -272,7 +272,10 @@ static zend_always_inline int zend_cpu_supports_avx512_vbmi(void) { #endif /* __builtin_cpu_supports has pclmul from gcc9 and clang 19 */ -#if defined(PHP_HAVE_BUILTIN_CPU_SUPPORTS) && (!defined(__GNUC__) || (defined(__clang__) && __clang_major__ >= 19) || (ZEND_GCC_VERSION >= 9000)) +#if defined(PHP_HAVE_BUILTIN_CPU_SUPPORTS) && (defined(__x86_64__) || defined(__i386__)) && \ + ( \ + (!defined(__GNUC__) || (defined(__clang__) && __clang_major__ >= 19) || (ZEND_GCC_VERSION >= 9000)) \ + ) ZEND_NO_SANITIZE_ADDRESS static inline int zend_cpu_supports_pclmul(void) { #ifdef PHP_HAVE_BUILTIN_CPU_INIT @@ -287,7 +290,11 @@ static inline int zend_cpu_supports_pclmul(void) { #endif /* __builtin_cpu_supports has cldemote from gcc11 and clang 19 */ -#if defined(PHP_HAVE_BUILTIN_CPU_SUPPORTS) && ((defined(__clang__) && (__clang_major__ >= 19)) || (!defined(__clang__) && defined(__GNUC__) && (ZEND_GCC_VERSION >= 11000))) +#if defined(PHP_HAVE_BUILTIN_CPU_SUPPORTS) && (defined(__x86_64__) || defined(__i386__)) && \ + ( \ + (defined(__clang__) && (__clang_major__ >= 19)) || \ + (!defined(__clang__) && defined(__GNUC__) && (ZEND_GCC_VERSION >= 11000)) \ + ) #define HAVE_ZEND_CPU_SUPPORTS_CLDEMOTE 1 ZEND_NO_SANITIZE_ADDRESS static inline int zend_cpu_supports_cldemote(void) { diff --git a/ext/lexbor/config.m4 b/ext/lexbor/config.m4 index 21fabcd0ddb0..a75f490e77cc 100644 --- a/ext/lexbor/config.m4 +++ b/ext/lexbor/config.m4 @@ -1,4 +1,4 @@ -PHP_LEXBOR_CFLAGS="-I@ext_srcdir@/" +PHP_LEXBOR_CFLAGS="-Wno-unknown-warning-option -Wno-unterminated-string-initialization -I@ext_srcdir@/" LEXBOR_DIR="lexbor" AC_DEFINE([HAVE_LEXBOR], [1], [Define to 1 if the PHP extension 'lexbor' is available.])