Include unistd.h unconditionally on !windows

This commit is contained in:
Frank Denis
2026-07-08 22:12:29 +02:00
parent 66360d57df
commit 984c9f3828
+2 -6
View File
@@ -940,9 +940,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"],[
AC_MSG_CHECKING(for getrandom with a standard API)
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include <unistd.h>
#ifdef HAVE_SYS_RANDOM_H
# include <sys/random.h>
#endif
@@ -960,9 +958,7 @@ if (&getrandom != NULL) {
AC_MSG_CHECKING(for getentropy with a standard API)
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#include <unistd.h>
#ifdef HAVE_SYS_RANDOM_H
# include <sys/random.h>
#endif