aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac39
1 files changed, 19 insertions, 20 deletions
diff --git a/configure.ac b/configure.ac
index d1eaa64e..847aefcb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -347,30 +347,29 @@ esac
347AC_SUBST(HIDDEN_VISIBILITY_CFLAGS) 347AC_SUBST(HIDDEN_VISIBILITY_CFLAGS)
348 348
349# libcurl (required for testing) 349# libcurl (required for testing)
350SAVE_LIBS=$LIBS
351
352AC_MSG_CHECKING(whether to use libcurl for testing)
353AC_ARG_ENABLE([curl], 350AC_ARG_ENABLE([curl],
354 [AS_HELP_STRING([--disable-curl],[disable cURL based testcases])], 351 [AS_HELP_STRING([--disable-curl],[disable cURL based testcases])],
355 [enable_curl=${enableval}], 352 [enable_curl=${enableval}])
356 [enable_curl=yes])
357AC_MSG_RESULT($enable_curl)
358curl=0 353curl=0
359if test "$enable_curl" = "yes" 354if test "$enable_curl" != "no"
355then
356 LIBCURL_CHECK_CONFIG([yes],[7.16.4],[enable_curl=yes],
357 [
358 if test "x$enable_curl" = "xyes"; then
359 AC_MSG_WARN([[cURL-based tests cannot be enabled because libcurl is missing]])
360 fi
361 enable_curl=no
362 ])
363fi
364if test "$enable_curl" != "no"
360then 365then
361 LIBCURL_CHECK_CONFIG(,,curl=1,curl=0)
362 AC_CHECK_HEADERS([curl/curl.h],[
363# Lib cURL & cURL - OpenSSL versions 366# Lib cURL & cURL - OpenSSL versions
364 MHD_REQ_CURL_VERSION=7.16.4 367 AC_DEFINE([MHD_REQ_CURL_VERSION], ["7.16.4"], [required cURL version to run tests])
365 MHD_REQ_CURL_OPENSSL_VERSION=0.9.8 368 AC_DEFINE([MHD_REQ_CURL_OPENSSL_VERSION], ["0.9.8"], [required cURL SSL version to run tests])
366 MHD_REQ_CURL_GNUTLS_VERSION=2.8.6 369 AC_DEFINE([MHD_REQ_CURL_GNUTLS_VERSION], ["2.8.6"], [gnuTLS lib version - used in conjunction with cURL])
367 MHD_REQ_CURL_NSS_VERSION=3.12.0 370 AC_DEFINE([MHD_REQ_CURL_NSS_VERSION], ["3.12.0"], [NSS lib version - used in conjunction with cURL])
368 AC_DEFINE_UNQUOTED([MHD_REQ_CURL_VERSION], "$MHD_REQ_CURL_VERSION", [required cURL version to run tests])
369 AC_DEFINE_UNQUOTED([MHD_REQ_CURL_OPENSSL_VERSION], "$MHD_REQ_CURL_OPENSSL_VERSION", [required cURL SSL version to run tests])
370 AC_DEFINE_UNQUOTED([MHD_REQ_CURL_GNUTLS_VERSION], "$MHD_REQ_CURL_GNUTLS_VERSION", [gnuTLS lib version - used in conjunction with cURL])
371 AC_DEFINE_UNQUOTED([MHD_REQ_CURL_NSS_VERSION], "$MHD_REQ_CURL_NSS_VERSION", [NSS lib version - used in conjunction with cURL])
372 ],[curl=0])
373fi 371fi
372AM_CONDITIONAL([HAVE_CURL], [test "x$enable_curl" = "xyes"])
374 373
375AC_CHECK_LIB([[magic]], [[magic_open]], 374AC_CHECK_LIB([[magic]], [[magic_open]],
376 [AC_CHECK_HEADERS([magic.h], 375 [AC_CHECK_HEADERS([magic.h],
@@ -410,6 +409,7 @@ AM_CONDITIONAL(ENABLE_SPDY, [test "x$enable_spdy" != "xno"])
410AC_MSG_CHECKING(whether we have OpenSSL and thus can support libmicrospdy) 409AC_MSG_CHECKING(whether we have OpenSSL and thus can support libmicrospdy)
411AC_MSG_RESULT($enable_spdy) 410AC_MSG_RESULT($enable_spdy)
412 411
412SAVE_LIBS=$LIBS
413spdy_OPENSSL 413spdy_OPENSSL
414# for pkg-config 414# for pkg-config
415SPDY_LIBDEPS="" 415SPDY_LIBDEPS=""
@@ -427,7 +427,6 @@ AC_SUBST(SPDY_LIBDEPS)
427 427
428 428
429LIBS=$SAVE_LIBS 429LIBS=$SAVE_LIBS
430AM_CONDITIONAL(HAVE_CURL, test x$curl = x1)
431 430
432# large file support (> 4 GB) 431# large file support (> 4 GB)
433AC_SYS_LARGEFILE 432AC_SYS_LARGEFILE
@@ -613,7 +612,7 @@ src/testzzuf/Makefile])
613AC_OUTPUT 612AC_OUTPUT
614 613
615# Finally: summary 614# Finally: summary
616if test "$curl" != 1 ; then 615if test "x$enable_curl" != "xyes"; then
617 MSG_CURL="no, many unit tests will not run" 616 MSG_CURL="no, many unit tests will not run"
618else 617else
619 MSG_CURL="yes" 618 MSG_CURL="yes"