0
0
mirror of https://github.com/zeromq/libzmq.git synced 2024-12-25 22:30:51 +08:00

build: fix mkdtemp check on macOS

On macOS, mkdtemp is in unistd.h. Fix the CMake check so that is works.
This was discovered when comparing the output of the Autotools an CMake
build systems.
This commit is contained in:
fanquake 2024-03-25 12:15:01 +00:00 committed by Luca Boccassi
parent 45b2924a0a
commit 4a5ece54b8

View File

@ -605,7 +605,7 @@ if(NOT MSVC)
check_cxx_symbol_exists(fork unistd.h HAVE_FORK)
check_cxx_symbol_exists(gethrtime sys/time.h HAVE_GETHRTIME)
check_cxx_symbol_exists(mkdtemp stdlib.h HAVE_MKDTEMP)
check_cxx_symbol_exists(mkdtemp "stdlib.h;unistd.h" HAVE_MKDTEMP)
check_cxx_symbol_exists(accept4 sys/socket.h HAVE_ACCEPT4)
check_cxx_symbol_exists(strnlen string.h HAVE_STRNLEN)
else()