summaryrefslogtreecommitdiff
path: root/acinclude.m4
diff options
context:
space:
mode:
authorMichael Fox <415fox@gmail.com>2012-02-16 10:02:49 +0900
committerMartin Sustrik <sustrik@250bpm.com>2012-02-16 10:02:49 +0900
commiteeb7e724560f8ed3d830726492e0a37f5a438115 (patch)
tree9b229130309c9531277589af85dcab74ced42669 /acinclude.m4
parentc7dd16074c22d262fa7e904af84b8add530b1ce2 (diff)
Fix: Case where system library has epoll but kernel does not support it.
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m47
1 files changed, 5 insertions, 2 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 531568d..e2e3951 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -629,17 +629,20 @@ dnl # LIBXS_CHECK_POLLER_EPOLL([action-if-found], [action-if-not-found])
dnl # Checks epoll polling system #
dnl ################################################################################
AC_DEFUN([LIBXS_CHECK_POLLER_EPOLL], [{
- AC_LINK_IFELSE(
+ AC_RUN_IFELSE(
[AC_LANG_PROGRAM(
[
#include <sys/epoll.h>
],
[[
struct epoll_event t_ev;
-epoll_create(10);
+int r;
+r = epoll_create(10);
+return(r < 0);
]]
)],
[libxs_cv_have_poller_epoll="yes" ; $1],
+ [libxs_cv_have_poller_epoll="no" ; $2],
[libxs_cv_have_poller_epoll="no" ; $2])
}])