aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac44
1 files changed, 38 insertions, 6 deletions
diff --git a/configure.ac b/configure.ac
index c4380511..8f64f6c7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3,7 +3,7 @@
3# 3#
4# libmicrohttpd is free software; you can redistribute it and/or modify 4# libmicrohttpd is free software; you can redistribute it and/or modify
5# it under the terms of the GNU General Public License as published 5# it under the terms of the GNU General Public License as published
6# by the Free Software Foundation; either version 2, or (at your 6# by the Free Software Foundation; either version 3, or (at your
7# option) any later version. 7# option) any later version.
8# 8#
9# libmicrohttpd is distributed in the hope that it will be useful, but 9# libmicrohttpd is distributed in the hope that it will be useful, but
@@ -21,15 +21,15 @@
21# 21#
22# 22#
23AC_PREREQ(2.57) 23AC_PREREQ(2.57)
24AC_INIT([libmicrohttpd], [0.9.27],[libmicrohttpd@gnu.org]) 24AC_INIT([libmicrohttpd], [0.9.28],[libmicrohttpd@gnu.org])
25AM_INIT_AUTOMAKE([silent-rules]) 25AM_INIT_AUTOMAKE([silent-rules])
26AC_CONFIG_HEADERS([MHD_config.h]) 26AC_CONFIG_HEADERS([MHD_config.h])
27AC_CONFIG_MACRO_DIR([m4]) 27AC_CONFIG_MACRO_DIR([m4])
28AH_TOP([#define _GNU_SOURCE 1]) 28AH_TOP([#define _GNU_SOURCE 1])
29 29
30LIB_VERSION_CURRENT=27 30LIB_VERSION_CURRENT=28
31LIB_VERSION_REVISION=0 31LIB_VERSION_REVISION=0
32LIB_VERSION_AGE=17 32LIB_VERSION_AGE=18
33AC_SUBST(LIB_VERSION_CURRENT) 33AC_SUBST(LIB_VERSION_CURRENT)
34AC_SUBST(LIB_VERSION_REVISION) 34AC_SUBST(LIB_VERSION_REVISION)
35AC_SUBST(LIB_VERSION_AGE) 35AC_SUBST(LIB_VERSION_AGE)
@@ -96,7 +96,7 @@ fi
96 96
97# for pkg-config 97# for pkg-config
98MHD_LIBDEPS="" 98MHD_LIBDEPS=""
99 99epoll=0
100# Check system type 100# Check system type
101case "$host_os" in 101case "$host_os" in
102*darwin* | *rhapsody* | *macosx*) 102*darwin* | *rhapsody* | *macosx*)
@@ -136,13 +136,27 @@ netbsd*)
136 AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets]) 136 AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets])
137 CFLAGS="-D_REENTRANT -fPIC -pipe $CFLAGS" 137 CFLAGS="-D_REENTRANT -fPIC -pipe $CFLAGS"
138 AM_CONDITIONAL(HAVE_GNU_LD, true) 138 AM_CONDITIONAL(HAVE_GNU_LD, true)
139 AM_CONDITIONAL(HAVE_W32, false) 139 AM_CONDITIONAL(HAVE_W32, false)
140 AC_MSG_CHECKING(whether to support epoll)
141 AC_ARG_ENABLE([epoll],
142 AS_HELP_STRING([--disable-epoll],
143 [disable epoll]),
144 [enable_epoll=${enableval}],
145 [enable_epoll=yes])
146 AC_MSG_RESULT($enable_epoll)
140 ;; 147 ;;
141*linux*) 148*linux*)
142 AC_DEFINE_UNQUOTED(LINUX,1,[This is a Linux kernel]) 149 AC_DEFINE_UNQUOTED(LINUX,1,[This is a Linux kernel])
143 AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets]) 150 AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets])
144 AM_CONDITIONAL(HAVE_GNU_LD, true) 151 AM_CONDITIONAL(HAVE_GNU_LD, true)
145 AM_CONDITIONAL(HAVE_W32, false) 152 AM_CONDITIONAL(HAVE_W32, false)
153 AC_MSG_CHECKING(whether to support epoll)
154 AC_ARG_ENABLE([epoll],
155 AS_HELP_STRING([--disable-epoll],
156 [disable epoll]),
157 [enable_epoll=${enableval}],
158 [enable_epoll=yes])
159 AC_MSG_RESULT($enable_epoll)
146 ;; 160 ;;
147*cygwin*) 161*cygwin*)
148 AC_DEFINE_UNQUOTED(CYGWIN,1,[This is a Cygwin system]) 162 AC_DEFINE_UNQUOTED(CYGWIN,1,[This is a Cygwin system])
@@ -180,6 +194,23 @@ netbsd*)
180;; 194;;
181esac 195esac
182 196
197
198if test "$enable_epoll" = "yes"
199then
200 AC_CHECK_HEADERS([sys/epoll.h],
201 [enable_epoll="yes"],
202 [enable_epoll="no"])
203fi
204
205if test "$enable_epoll" = "yes"
206then
207 AC_DEFINE([EPOLL_SUPPORT],[1],[include epoll support])
208else
209 AC_DEFINE([EPOLL_SUPPORT],[0],[disable epoll support])
210fi
211AM_CONDITIONAL(ENABLE_EPOLL, [test "x$enable_epoll" != "xno"])
212
213
183CHECK_PTHREAD 214CHECK_PTHREAD
184LIBS="$PTHREAD_LIBS $LIBS" 215LIBS="$PTHREAD_LIBS $LIBS"
185AC_SUBST(PTHREAD_LIBS) 216AC_SUBST(PTHREAD_LIBS)
@@ -547,6 +578,7 @@ AC_MSG_NOTICE([Configuration Summary:
547 Digest auth.: ${enable_dauth} 578 Digest auth.: ${enable_dauth}
548 Postproc: ${enable_postprocessor} 579 Postproc: ${enable_postprocessor}
549 HTTPS support: ${enable_https} 580 HTTPS support: ${enable_https}
581 epoll support: ${enable_epoll}
550 libmicrospdy: ${enable_spdy} 582 libmicrospdy: ${enable_spdy}
551 spdylay (testing): ${have_spdylay} 583 spdylay (testing): ${have_spdylay}
552]) 584])