diff options
author | Gabriele Svelto <gabriele.svelto@gmail.com> | 2012-04-07 23:04:14 +0200 |
---|---|---|
committer | Martin Sustrik <sustrik@250bpm.com> | 2012-04-09 06:24:37 +0200 |
commit | dcc894ec6fb46f0c4739434f8013914b8a6f8a88 (patch) | |
tree | 2b60ec817a0ea6b090e5ac6cd9278f2d5ca5fb54 | |
parent | f3d6779cb7ab76eab9b5558100ec57bbed9dc497 (diff) |
Fix /dev/poll detection on Solaris
The /dev/poll facility wasn't correctly recognized because of a missing
header. The check was fixed and overhauled in the process.
Signed-off-by: Gabriele Svelto <gabriele.svelto@gmail.com>
-rw-r--r-- | acinclude.m4 | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/acinclude.m4 b/acinclude.m4 index a1c1cbe..169c786 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -651,11 +651,18 @@ AC_DEFUN([LIBXS_CHECK_POLLER_DEVPOLL], [{ AC_LINK_IFELSE( [AC_LANG_PROGRAM( [ +#include <sys/ioctl.h> +#include <sys/stat.h> +#include <sys/types.h> +#include <sys/poll.h> #include <sys/devpoll.h> ], [[ -struct pollfd t_devpoll; -int fd = open("/dev/poll", O_RDWR); +struct dvpoll p; +p.dp_timeout = 0; +p.dp_nfds = 0; +p.dp_fds = (struct pollfd *) 0; +return 0; ]] )], [libxs_cv_have_poller_devpoll="yes" ; $1], |