summaryrefslogtreecommitdiffstats
path: root/fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake')
-rw-r--r--fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake18
1 files changed, 18 insertions, 0 deletions
diff --git a/fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake b/fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake
new file mode 100644
index 000000000..1a73db37b
--- /dev/null
+++ b/fluent-bit/lib/monkey/mk_core/deps/libevent/cmake/CheckWaitpidSupportWNOWAIT.cmake
@@ -0,0 +1,18 @@
+include(CheckCSourceRuns)
+
+check_c_source_runs(
+"
+#include <unistd.h>
+#include <sys/types.h>
+#include <sys/wait.h>
+#include <stdlib.h>
+
+int
+main(int argc, char** argv)
+{
+ pid_t pid;
+ int status;
+ if ((pid = fork()) == 0) _exit(0);
+ _exit(waitpid(pid, &status, WNOWAIT) == -1);
+}"
+EVENT__HAVE_WAITPID_WITH_WNOWAIT)