Fix build on systems that lack O_CLOEXEC definition

* 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.
This commit is contained in:
Дмитрий Левин 2015-08-24 09:38:03 +00:00
parent 3595f4ae15
commit 12cca59aed
4 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,5 @@
EFD_SEMAPHORE 1
#if defined EFD_CLOEXEC || defined O_CLOEXEC
EFD_CLOEXEC O_CLOEXEC
#endif
EFD_NONBLOCK O_NONBLOCK

View File

@ -1 +1,3 @@
#if defined EPOLL_CLOEXEC || defined O_CLOEXEC
EPOLL_CLOEXEC O_CLOEXEC
#endif

View File

@ -1,2 +1,4 @@
#if defined SFD_CLOEXEC || defined O_CLOEXEC
SFD_CLOEXEC O_CLOEXEC
#endif
SFD_NONBLOCK O_NONBLOCK

View 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