Skip to content

Commit e2b7fdd

Browse files
committed
gh-138850: Add --disable-epoll to configure
1 parent c4333a1 commit e2b7fdd

2 files changed

Lines changed: 41 additions & 2 deletions

File tree

configure

Lines changed: 27 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configure.ac

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5380,8 +5380,20 @@ PY_CHECK_FUNC([symlink], [@%:@include <unistd.h>])
53805380
PY_CHECK_FUNC([fchdir], [@%:@include <unistd.h>])
53815381
PY_CHECK_FUNC([fsync], [@%:@include <unistd.h>])
53825382
PY_CHECK_FUNC([fdatasync], [@%:@include <unistd.h>])
5383-
PY_CHECK_FUNC([epoll_create], [@%:@include <sys/epoll.h>], [HAVE_EPOLL])
5384-
PY_CHECK_FUNC([epoll_create1], [@%:@include <sys/epoll.h>])
5383+
5384+
AC_MSG_CHECKING([for --disable-epoll])
5385+
AC_ARG_ENABLE([epoll],
5386+
[AS_HELP_STRING([--disable-epoll], [disable epoll (default is yes if supported)])],
5387+
[AS_VAR_IF([enable_epoll], [no], [disable_epoll=yes], [disable_epoll=no])],
5388+
[disable_epoll=no]
5389+
)
5390+
AC_MSG_RESULT([$disable_epoll])
5391+
if test "$disable_epoll" = "no"
5392+
then
5393+
PY_CHECK_FUNC([epoll_create], [@%:@include <sys/epoll.h>], [HAVE_EPOLL])
5394+
PY_CHECK_FUNC([epoll_create1], [@%:@include <sys/epoll.h>])
5395+
fi
5396+
53855397
PY_CHECK_FUNC([kqueue],[
53865398
#include <sys/types.h>
53875399
#include <sys/event.h>

0 commit comments

Comments
 (0)