Skip to content

Commit 8f4dc71

Browse files
authored
build: Fix check for sigsetjmp (#12606)
The usual check for presence of sigsetjmp will not be sufficient since the sigsetjmp might be defined as a macro.
1 parent 7d485aa commit 8f4dc71

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Zend/Zend.m4

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,13 @@ _LT_AC_TRY_DLOPEN_SELF([
146146
])
147147
148148
dnl Checks for library functions.
149-
AC_CHECK_FUNCS(getpid kill sigsetjmp pthread_getattr_np pthread_attr_get_np pthread_get_stackaddr_np pthread_attr_getstack pthread_stackseg_np gettid)
149+
AC_CHECK_FUNCS(getpid kill pthread_getattr_np pthread_attr_get_np pthread_get_stackaddr_np pthread_attr_getstack pthread_stackseg_np gettid)
150+
151+
dnl Check for sigsetjmp. If it's defined as a macro, AC_CHECK_FUNCS won't work.
152+
AC_CHECK_FUNCS([sigsetjmp],,
153+
[AC_CHECK_DECL([sigsetjmp],
154+
[AC_DEFINE([HAVE_SIGSETJMP],[1],[Define to 1 if you have the 'sigsetjmp' function.])],,
155+
[#include <setjmp.h>])])
150156
151157
dnl Test whether the stack grows downwards
152158
dnl Assumes contiguous stack

0 commit comments

Comments
 (0)