diff options
author | Christian Grothoff <christian@grothoff.org> | 2023-11-13 16:37:50 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2023-11-13 16:37:50 +0100 |
commit | d45a14fea57ed340f8199460afa12192dc94a6e4 (patch) | |
tree | fcd09a4677dcd58ccb559e397f0e84511b16acc6 | |
parent | 0255fb4a2357392f1676e3a48d5dd81168f2f9d1 (diff) |
fix check order
-rw-r--r-- | configure.ac | 72 |
1 files changed, 36 insertions, 36 deletions
diff --git a/configure.ac b/configure.ac index de81cc87c..7d0e14d75 100644 --- a/configure.ac +++ b/configure.ac @@ -128,6 +128,42 @@ fd = epoll_create1(EPOLL_CLOEXEC);]])], AC_DEFINE([[HAVE_EPOLL_CREATE1]], [[1]], [Define if you have epoll_create1 function.])])) +# check for libmicrohttpd +AC_MSG_CHECKING([for microhttpd]) +AC_ARG_WITH([microhttpd], + [AS_HELP_STRING([--with-microhttpd=PFX], [base of microhttpd installation])], + [AC_MSG_RESULT([given as $with_microhttpd])], + [AC_MSG_RESULT([not given]) + with_microhttpd=yes]) +AS_CASE([$with_microhttpd], + [yes], [], + [no], [AC_MSG_ERROR([--with-microhttpd is required])], + [LDFLAGS="-L$with_microhttpd/lib $LDFLAGS" + CPPFLAGS="-I$with_microhttpd/include $CPPFLAGS"]) +MHD_VERSION_AT_LEAST([0.9.71]) + +# check for libjansson (Jansson JSON library) +jansson=0 +AC_MSG_CHECKING([for jansson]) +AC_ARG_WITH([jansson], + [AS_HELP_STRING([--with-jansson=PFX], [base of jansson installation])], + [AC_MSG_RESULT([given as $with_jansson])], + [AC_MSG_RESULT([not given]) + with_jansson=yes]) +AS_CASE([$with_jansson], + [yes], [], + [no], [AC_MSG_ERROR([--with-jansson is required])], + [LDFLAGS="-L$with_jansson/lib $LDFLAGS" + CPPFLAGS="-I$with_jansson/include $CPPFLAGS"]) +AC_CHECK_LIB(jansson,json_dumpb, + [AC_CHECK_HEADER([jansson.h],[jansson=1])]) +AS_IF([test $jansson = 0], + [AC_MSG_ERROR([[ +*** +*** You need libjansson >= 2.10 to build this program. +*** ]])]) + + # Check for GNUnet's libgnunetutil. libgnunetutil=0 AC_MSG_CHECKING([for libgnunetutil]) @@ -295,42 +331,6 @@ AC_CHECK_HEADERS([gnunet/gnunet_sq_lib.h], [AC_CHECK_LIB([gnunetsq], [GNUNET_SQ_result_spec_string], libgnunetsq=1)]) -# check for libmicrohttpd -AC_MSG_CHECKING([for microhttpd]) -AC_ARG_WITH([microhttpd], - [AS_HELP_STRING([--with-microhttpd=PFX], [base of microhttpd installation])], - [AC_MSG_RESULT([given as $with_microhttpd])], - [AC_MSG_RESULT([not given]) - with_microhttpd=yes]) -AS_CASE([$with_microhttpd], - [yes], [], - [no], [AC_MSG_ERROR([--with-microhttpd is required])], - [LDFLAGS="-L$with_microhttpd/lib $LDFLAGS" - CPPFLAGS="-I$with_microhttpd/include $CPPFLAGS"]) -MHD_VERSION_AT_LEAST([0.9.71]) - -# check for libjansson (Jansson JSON library) -jansson=0 -AC_MSG_CHECKING([for jansson]) -AC_ARG_WITH([jansson], - [AS_HELP_STRING([--with-jansson=PFX], [base of jansson installation])], - [AC_MSG_RESULT([given as $with_jansson])], - [AC_MSG_RESULT([not given]) - with_jansson=yes]) -AS_CASE([$with_jansson], - [yes], [], - [no], [AC_MSG_ERROR([--with-jansson is required])], - [LDFLAGS="-L$with_jansson/lib $LDFLAGS" - CPPFLAGS="-I$with_jansson/include $CPPFLAGS"]) -AC_CHECK_LIB(jansson,json_dumpb, - [AC_CHECK_HEADER([jansson.h],[jansson=1])]) -AS_IF([test $jansson = 0], - [AC_MSG_ERROR([[ -*** -*** You need libjansson >= 2.10 to build this program. -*** ]])]) - - CFLAGS=$CFLAGS_SAVE LDFLAGS=$LDFLAGS_SAVE |