ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/libev.m4
(Generate patch)

Comparing libev/libev.m4 (file contents):
Revision 1.4 by root, Sun Nov 18 02:17:58 2007 UTC vs.
Revision 1.17 by root, Thu Jun 20 23:14:54 2019 UTC

1dnl this file is part of libev, do not make local modifications 1dnl this file is part of libev, do not make local modifications
2dnl http://software.schmorp.de/pkg/libev 2dnl http://software.schmorp.de/pkg/libev
3 3
4dnl libev support 4dnl libev support
5AC_CHECK_HEADERS(sys/epoll.h sys/event.h sys/queue.h port.h poll.h sys/select.h) 5AC_CHECK_HEADERS(sys/inotify.h sys/epoll.h sys/event.h port.h poll.h)
6AC_CHECK_HEADERS(sys/select.h sys/eventfd.h sys/signalfd.h linux/aio_abi.h)
6 7
7AC_CHECK_FUNCS(epoll_ctl kqueue port_create poll select) 8AC_CHECK_FUNCS(inotify_init epoll_ctl kqueue port_create poll select eventfd signalfd)
8 9
9AC_CHECK_FUNC(clock_gettime, [], [ 10AC_CHECK_FUNCS(clock_gettime, [], [
10 if test -z "$LIBEV_M4_AVOID_LIBRT"; then 11 dnl on linux, try syscall wrapper first
12 if test $(uname) = Linux; then
13 AC_MSG_CHECKING(for clock_gettime syscall)
14 AC_LINK_IFELSE([AC_LANG_PROGRAM(
15 [#include <unistd.h>
16 #include <sys/syscall.h>
17 #include <time.h>],
18 [struct timespec ts; int status = syscall (SYS_clock_gettime, CLOCK_REALTIME, &ts)])],
19 [ac_have_clock_syscall=1
20 AC_DEFINE(HAVE_CLOCK_SYSCALL, 1, Define to 1 to use the syscall interface for clock_gettime)
21 AC_MSG_RESULT(yes)],
22 [AC_MSG_RESULT(no)])
23 fi
24 if test -z "$LIBEV_M4_AVOID_LIBRT" && test -z "$ac_have_clock_syscall"; then
11 AC_CHECK_LIB(rt, clock_gettime) 25 AC_CHECK_LIB(rt, clock_gettime)
26 unset ac_cv_func_clock_gettime
12 AC_CHECK_FUNCS(clock_gettime) 27 AC_CHECK_FUNCS(clock_gettime)
13 fi 28 fi
14]) 29])
15 30
16AC_CHECK_LIB(m, ceil) 31AC_CHECK_FUNCS(nanosleep, [], [
32 if test -z "$LIBEV_M4_AVOID_LIBRT"; then
33 AC_CHECK_LIB(rt, nanosleep)
34 unset ac_cv_func_nanosleep
35 AC_CHECK_FUNCS(nanosleep)
36 fi
37])
17 38
39if test -z "$LIBEV_M4_AVOID_LIBM"; then
40 LIBM=m
41fi
42AC_SEARCH_LIBS(floor, $LIBM, [AC_DEFINE(HAVE_FLOOR, 1, Define to 1 if the floor function is available)])
18 43
19

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines