]> granicus.if.org Git - strace/commitdiff
Fix build on systems that lack O_CLOEXEC definition
authorDmitry V. Levin <ldv@altlinux.org>
Mon, 24 Aug 2015 09:38:03 +0000 (09:38 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 25 Aug 2015 10:05:08 +0000 (10:05 +0000)
* xlat/efd_flags.in: Check that O_CLOEXEC is defined.
* xlat/epollflags.in: Likewise.
* xlat/sfd_flags.in: Likewise.
* xlat/timerfdflags.in: Fix O_CLOEXEC check.

xlat/efd_flags.in
xlat/epollflags.in
xlat/sfd_flags.in
xlat/timerfdflags.in

index 0db0ade698af245e804709693a2c8bf952a5d394..258fb9f0dbf377c49acee46c44c789db8c0215d8 100644 (file)
@@ -1,3 +1,5 @@
 EFD_SEMAPHORE  1
+#if defined EFD_CLOEXEC || defined O_CLOEXEC
 EFD_CLOEXEC    O_CLOEXEC
+#endif
 EFD_NONBLOCK   O_NONBLOCK
index 4f6b192f5f3f6149c48c3e034d3ed9f510d21b97..e7ebaafd43e792b334566f595830bf4a9ef5e534 100644 (file)
@@ -1 +1,3 @@
+#if defined EPOLL_CLOEXEC || defined O_CLOEXEC
 EPOLL_CLOEXEC  O_CLOEXEC
+#endif
index badd55dae419f5f741dc376afbf947d2b428ff68..20a5d1f85e265e4ebb953ce2028ba3ea88f87245 100644 (file)
@@ -1,2 +1,4 @@
+#if defined SFD_CLOEXEC || defined O_CLOEXEC
 SFD_CLOEXEC    O_CLOEXEC
+#endif
 SFD_NONBLOCK   O_NONBLOCK
index 6c934bdc4c15d46b2a7caf2961f98631b41683fb..bf767e3f4af1fc8493ec04a86bf085212da3c472 100644 (file)
@@ -2,7 +2,7 @@
 
 TFD_TIMER_ABSTIME (1 << 0)
 TFD_TIMER_CANCEL_ON_SET (1 << 1)
-#ifdef O_CLOEXEC
+#if defined TFD_CLOEXEC || defined O_CLOEXEC
 TFD_CLOEXEC O_CLOEXEC
 #endif
 TFD_NONBLOCK O_NONBLOCK