aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-04-22 14:16:25 +0000
committerChristian Grothoff <christian@grothoff.org>2012-04-22 14:16:25 +0000
commitd0c4bdb23f28a8a7057814ae6aa690c53922ba76 (patch)
tree19b9196393258ca4c5213664c39eb844818523ff /configure.ac
parent6460e38ae3550c54413135cc603e5036b50f6ae5 (diff)
-adding improved test for libmicrohttpd
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac27
1 files changed, 24 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index 27fa591047..e42c6bcaf5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -567,7 +567,14 @@ AC_ARG_WITH(microhttpd,
AC_CHECK_HEADERS([microhttpd.h],
AC_CHECK_DECL(MHD_OPTION_PER_IP_CONNECTION_LIMIT,
AC_CHECK_LIB([microhttpd], [MHD_start_daemon],
- lmhd=1),
+ [AC_MSG_CHECKING([for libmicrohttpd >= 0.9.18])
+ AC_RUN_IFELSE([
+ #include "$srcdir/src/include/platform.h"
+ #include <microhttpd.h>
+ int main () { return MHD_VERSION >= 0x0091200 ? 0 : 1; }
+ ], [
+ AC_MSG_RESULT(ok)
+ lmhd=1],[AC_MSG_RESULT(failed)],lmhd=1)]),
[],[#include "$srcdir/src/include/platform.h"
#include <microhttpd.h>]),,
[#include "$srcdir/src/include/platform.h"])
@@ -579,7 +586,14 @@ AC_ARG_WITH(microhttpd,
AC_CHECK_DECL(MHD_OPTION_PER_IP_CONNECTION_LIMIT,
AC_CHECK_LIB([microhttpd], [MHD_start_daemon],
EXT_LIB_PATH="-L$with_microhttpd/lib $EXT_LIB_PATH"
- lmhd=1),
+ [AC_MSG_CHECKING([for libmicrohttpd >= 0.9.18])
+ AC_RUN_IFELSE([
+ #include "$srcdir/src/include/platform.h"
+ #include <microhttpd.h>
+ int main () { return MHD_VERSION >= 0x0091200 ? 0 : 1; }
+ ], [
+ AC_MSG_RESULT(ok)
+ lmhd=1],[AC_MSG_RESULT(failed)],lmhd=1)]),
[],[#include "$srcdir/src/include/platform.h"
#include <microhttpd.h>]),,
[#include "$srcdir/src/include/platform.h"])
@@ -590,7 +604,14 @@ AC_ARG_WITH(microhttpd,
AC_CHECK_HEADERS([microhttpd.h],
AC_CHECK_DECL(MHD_OPTION_PER_IP_CONNECTION_LIMIT,
AC_CHECK_LIB([microhttpd], [MHD_start_daemon],
- lmhd=1),
+ [AC_MSG_CHECKING([for libmicrohttpd >= 0.9.18])
+ AC_RUN_IFELSE([
+ #include "$srcdir/src/include/platform.h"
+ #include <microhttpd.h>
+ int main () { return MHD_VERSION >= 0x0091200 ? 0 : 1; }
+ ], [
+ AC_MSG_RESULT(ok)
+ lmhd=1],[AC_MSG_RESULT(failed)],lmhd=1)]),
[],[#include "$srcdir/src/include/platform.h"
#include <microhttpd.h>]),,
[#include "$srcdir/src/include/platform.h"])])