mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-15 03:01:09 +08:00
Better test for epoll, make sure the syscall actually works
This commit is contained in:
parent
c3d40a6e6e
commit
984276d849
13
configure.in
13
configure.in
@ -887,9 +887,18 @@ AC_CHECK_FUNCS( poll )
|
||||
AC_CHECK_HEADERS( poll.h )
|
||||
|
||||
dnl ----------------------------------------------------------------
|
||||
AC_CHECK_FUNC(epoll_create, AC_DEFINE(HAVE_EPOLL,1,
|
||||
[define if you have epoll]))
|
||||
AC_CHECK_HEADERS( sys/epoll.h )
|
||||
if test "${ac_cv_header_sys_epoll_h}" = yes; then
|
||||
AC_MSG_CHECKING(for epoll system call)
|
||||
AC_TRY_RUN(
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
int epfd = epoll_create(256);
|
||||
exit (epfd == -1 ? 1 : 0);
|
||||
}, [AC_MSG_RESULT(yes)
|
||||
AC_DEFINE(HAVE_EPOLL,1, [define if your system supports epoll])],
|
||||
AC_MSG_RESULT(no),AC_MSG_RESULT(no))
|
||||
fi
|
||||
|
||||
dnl ----------------------------------------------------------------
|
||||
# strerror checks
|
||||
|
Loading…
Reference in New Issue
Block a user