@@ -258,9 +258,9 @@ include(PHP/CheckAVX512)
258258# Check functions.
259259################################################################################
260260
261- check_symbol_exists(alphasort " dirent.h" HAVE_ALPHASORT)
262- check_symbol_exists(explicit_memset " string.h" HAVE_EXPLICIT_MEMSET)
263- check_symbol_exists(fdatasync " unistd.h" HAVE_FDATASYNC)
261+ check_symbol_exists(alphasort dirent.h HAVE_ALPHASORT)
262+ check_symbol_exists(explicit_memset string .h HAVE_EXPLICIT_MEMSET)
263+ check_symbol_exists(fdatasync unistd.h HAVE_FDATASYNC)
264264# The fdatasync declaration on macOS is missing in headers, yet is in C library.
265265if (NOT HAVE_FDATASYNC)
266266 unset (HAVE_FDATASYNC CACHE )
@@ -279,9 +279,9 @@ block()
279279 check_symbol_exists(flock "${headers} " HAVE_FLOCK)
280280endblock()
281281
282- check_symbol_exists(ftok " sys/ipc.h" HAVE_FTOK)
283- check_symbol_exists(funopen " stdio.h" HAVE_FUNOPEN)
284- check_symbol_exists(getcwd " unistd.h" HAVE_GETCWD)
282+ check_symbol_exists(ftok sys/ipc.h HAVE_FTOK)
283+ check_symbol_exists(funopen stdio.h HAVE_FUNOPEN)
284+ check_symbol_exists(getcwd unistd.h HAVE_GETCWD)
285285
286286block()
287287 set (headers stdlib.h)
@@ -299,39 +299,39 @@ block()
299299 check_symbol_exists(getloadavg "${headers} " HAVE_GETLOADAVG)
300300endblock()
301301
302- check_symbol_exists(getlogin " unistd.h" HAVE_GETLOGIN)
303- check_symbol_exists(getrusage " sys/resource.h" HAVE_GETRUSAGE)
304- check_symbol_exists(gettimeofday " sys/time.h" HAVE_GETTIMEOFDAY)
305- check_symbol_exists(getpwnam_r " pwd.h" HAVE_GETPWNAM_R)
306- check_symbol_exists(getgrnam_r " grp.h" HAVE_GETGRNAM_R)
307- check_symbol_exists(getpwuid_r " pwd.h" HAVE_GETPWUID_R)
308- check_symbol_exists(getwd " unistd.h" HAVE_GETWD)
309- check_symbol_exists(glob " glob.h" HAVE_GLOB)
310- check_symbol_exists(lchown " unistd.h" HAVE_LCHOWN)
311- check_symbol_exists(memcntl " sys/mman.h" HAVE_MEMCNTL)
302+ check_symbol_exists(getlogin unistd.h HAVE_GETLOGIN)
303+ check_symbol_exists(getrusage sys/resource .h HAVE_GETRUSAGE)
304+ check_symbol_exists(gettimeofday sys/time.h HAVE_GETTIMEOFDAY)
305+ check_symbol_exists(getpwnam_r pwd.h HAVE_GETPWNAM_R)
306+ check_symbol_exists(getgrnam_r grp.h HAVE_GETGRNAM_R)
307+ check_symbol_exists(getpwuid_r pwd.h HAVE_GETPWUID_R)
308+ check_symbol_exists(getwd unistd.h HAVE_GETWD)
309+ check_symbol_exists(glob glob.h HAVE_GLOB)
310+ check_symbol_exists(lchown unistd.h HAVE_LCHOWN)
311+ check_symbol_exists(memcntl sys/mman.h HAVE_MEMCNTL)
312312
313313cmake_push_check_state(RESET)
314314 set (CMAKE_REQUIRED_DEFINITIONS -D_GNU_SOURCE)
315- check_symbol_exists(memfd_create " sys/mman.h" HAVE_MEMFD_CREATE)
315+ check_symbol_exists(memfd_create sys/mman.h HAVE_MEMFD_CREATE)
316316cmake_pop_check_state()
317317
318- check_symbol_exists(mkstemp " stdlib.h" HAVE_MKSTEMP)
319- check_symbol_exists(mmap " sys/mman.h" HAVE_MMAP)
320- check_symbol_exists(nice " unistd.h" HAVE_NICE)
321- check_symbol_exists(nl_langinfo " langinfo.h" HAVE_NL_LANGINFO)
322- check_symbol_exists(prctl " sys/prctl.h" HAVE_PRCTL)
323- check_symbol_exists(procctl " sys/procctl.h" HAVE_PROCCTL)
324- check_symbol_exists(poll " poll.h" HAVE_POLL)
318+ check_symbol_exists(mkstemp stdlib.h HAVE_MKSTEMP)
319+ check_symbol_exists(mmap sys/mman.h HAVE_MMAP)
320+ check_symbol_exists(nice unistd.h HAVE_NICE)
321+ check_symbol_exists(nl_langinfo langinfo.h HAVE_NL_LANGINFO)
322+ check_symbol_exists(prctl sys/prctl.h HAVE_PRCTL)
323+ check_symbol_exists(procctl sys/procctl.h HAVE_PROCCTL)
324+ check_symbol_exists(poll poll.h HAVE_POLL)
325325check_symbol_exists(
326326 pthread_jit_write_protect_np
327- " pthread.h"
327+ pthread.h
328328 HAVE_PTHREAD_JIT_WRITE_PROTECT_NP
329329)
330- check_symbol_exists(putenv " stdlib.h" HAVE_PUTENV)
331- check_symbol_exists(scandir " dirent.h" HAVE_SCANDIR)
332- check_symbol_exists(setitimer " sys/time.h" HAVE_SETITIMER)
333- check_symbol_exists(setenv " stdlib.h" HAVE_SETENV)
334- check_symbol_exists(sigprocmask " signal.h" HAVE_SIGPROCMASK)
330+ check_symbol_exists(putenv stdlib.h HAVE_PUTENV)
331+ check_symbol_exists(scandir dirent.h HAVE_SCANDIR)
332+ check_symbol_exists(setitimer sys/time.h HAVE_SETITIMER)
333+ check_symbol_exists(setenv stdlib.h HAVE_SETENV)
334+ check_symbol_exists(sigprocmask signal.h HAVE_SIGPROCMASK)
335335
336336# Check for statfs().
337337block()
@@ -349,39 +349,39 @@ block()
349349 check_symbol_exists(statfs "${headers} " HAVE_STATFS)
350350endblock()
351351
352- check_symbol_exists(statvfs " sys/statvfs.h" HAVE_STATVFS)
353- check_symbol_exists(std_syslog " sys/syslog.h" HAVE_STD_SYSLOG)
354- check_symbol_exists(strcasecmp " strings.h" HAVE_STRCASECMP)
355- check_symbol_exists(strnlen " string.h" HAVE_STRNLEN)
356- check_symbol_exists(symlink " unistd.h" HAVE_SYMLINK)
357- check_symbol_exists(tzset " time.h" HAVE_TZSET)
358- check_symbol_exists(unsetenv " stdlib.h" HAVE_UNSETENV)
359- check_symbol_exists(usleep " unistd.h" HAVE_USLEEP)
360- check_symbol_exists(utime " utime.h" HAVE_UTIME)
352+ check_symbol_exists(statvfs sys/statvfs.h HAVE_STATVFS)
353+ check_symbol_exists(std_syslog sys/syslog.h HAVE_STD_SYSLOG)
354+ check_symbol_exists(strcasecmp strings .h HAVE_STRCASECMP)
355+ check_symbol_exists(strnlen string .h HAVE_STRNLEN)
356+ check_symbol_exists(symlink unistd.h HAVE_SYMLINK)
357+ check_symbol_exists(tzset time.h HAVE_TZSET)
358+ check_symbol_exists(unsetenv stdlib.h HAVE_UNSETENV)
359+ check_symbol_exists(usleep unistd.h HAVE_USLEEP)
360+ check_symbol_exists(utime utime.h HAVE_UTIME)
361361
362362cmake_push_check_state(RESET)
363363 set (CMAKE_REQUIRED_DEFINITIONS -D_GNU_SOURCE)
364- check_symbol_exists(vasprintf " stdio.h" HAVE_VASPRINTF)
364+ check_symbol_exists(vasprintf stdio.h HAVE_VASPRINTF)
365365cmake_pop_check_state()
366366
367367cmake_push_check_state(RESET)
368368 set (CMAKE_REQUIRED_DEFINITIONS -D_GNU_SOURCE)
369- check_symbol_exists(asprintf " stdio.h" HAVE_ASPRINTF)
369+ check_symbol_exists(asprintf stdio.h HAVE_ASPRINTF)
370370cmake_pop_check_state()
371371
372372cmake_push_check_state(RESET)
373373 set (CMAKE_REQUIRED_DEFINITIONS -D_GNU_SOURCE)
374- check_symbol_exists(memmem " string.h" HAVE_MEMMEM)
374+ check_symbol_exists(memmem string .h HAVE_MEMMEM)
375375cmake_pop_check_state()
376376
377377cmake_push_check_state(RESET)
378378 set (CMAKE_REQUIRED_DEFINITIONS -D_GNU_SOURCE)
379- check_symbol_exists(memrchr " string.h" HAVE_MEMRCHR)
379+ check_symbol_exists(memrchr string .h HAVE_MEMRCHR)
380380cmake_pop_check_state()
381381
382- check_symbol_exists(strlcat " string.h" HAVE_STRLCAT)
383- check_symbol_exists(strlcpy " string.h" HAVE_STRLCPY)
384- check_symbol_exists(explicit_bzero " string.h" HAVE_EXPLICIT_BZERO)
382+ check_symbol_exists(strlcat string .h HAVE_STRLCAT)
383+ check_symbol_exists(strlcpy string .h HAVE_STRLCPY)
384+ check_symbol_exists(explicit_bzero string .h HAVE_EXPLICIT_BZERO)
385385
386386# Check reentrant functions.
387387include (PHP/CheckReentrantFunctions)
@@ -448,12 +448,12 @@ include(PHP/CheckFlushIo)
448448
449449if (HAVE_ALLOCA_H)
450450 # Most *.nix systems.
451- check_symbol_exists(alloca " alloca.h" HAVE_ALLOCA)
451+ check_symbol_exists(alloca alloca.h HAVE_ALLOCA)
452452elseif (CMAKE_SYSTEM_NAME STREQUAL "Windows" )
453- check_symbol_exists(alloca " malloc.h" HAVE_ALLOCA)
453+ check_symbol_exists(alloca malloc.h HAVE_ALLOCA)
454454else ()
455455 # BSD-based systems.
456- check_symbol_exists(alloca " stdlib.h" HAVE_ALLOCA)
456+ check_symbol_exists(alloca stdlib.h HAVE_ALLOCA)
457457endif ()
458458
459459message (CHECK_START "Checking whether the compiler supports __alignof__" )
0 commit comments