From d93800ec0f6dc070aefe13cca76d5b8d6f7b6483 Mon Sep 17 00:00:00 2001 From: Thomas Hurst Date: Fri, 22 Sep 2023 16:11:22 +0000 Subject: [PATCH] Fix GH-12273 - configure __builtin_cpu_init() check __builtin_cpu_init() is documented as having a void return type. It happens to return int on gcc, but is void on clang. Close GH-122274 --- NEWS | 1 + build/php.m4 | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 3349db3c9df..23bfdcebada 100644 --- a/NEWS +++ b/NEWS @@ -7,6 +7,7 @@ PHP NEWS (rioderelfte) . Fixed bug GH-12215 (Module entry being overwritten causes type errors in ext/dom). (nielsdos) + . Fixed bug GH-12273 (__builtin_cpu_init check). (Freaky) - Filter: . Fix explicit FILTER_REQUIRE_SCALAR with FILTER_CALLBACK (ilutov) diff --git a/build/php.m4 b/build/php.m4 index 0f5ee004926..adb2964e76d 100644 --- a/build/php.m4 +++ b/build/php.m4 @@ -2700,7 +2700,7 @@ AC_DEFUN([PHP_CHECK_BUILTIN_CPU_INIT], [ AC_MSG_CHECKING([for __builtin_cpu_init]) AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[ - return __builtin_cpu_init()? 1 : 0; + __builtin_cpu_init(); ]])], [ have_builtin_cpu_init=1 AC_MSG_RESULT([yes])