configure.ac 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949
  1. # This file is part of libmicrohttpd.
  2. # (C) 2006-2015 Christian Grothoff (and other contributing authors)
  3. #
  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
  6. # by the Free Software Foundation; either version 3, or (at your
  7. # option) any later version.
  8. #
  9. # libmicrohttpd is distributed in the hope that it will be useful, but
  10. # WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  12. # General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with libmicrohttpd; see the file COPYING. If not, write to the
  16. # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  17. # Boston, MA 02111-1307, USA.
  18. #
  19. #
  20. # Process this file with autoconf to produce a configure script.
  21. #
  22. #
  23. AC_PREREQ([2.60])
  24. LT_PREREQ([2.4.0])
  25. AC_INIT([libmicrohttpd],[0.9.42],[libmicrohttpd@gnu.org])
  26. AM_INIT_AUTOMAKE([silent-rules] [subdir-objects])
  27. AC_CONFIG_HEADERS([MHD_config.h])
  28. AC_CONFIG_MACRO_DIR([m4])
  29. AH_TOP([#define _GNU_SOURCE 1])
  30. LIB_VERSION_CURRENT=42
  31. LIB_VERSION_REVISION=0
  32. LIB_VERSION_AGE=32
  33. AC_SUBST(LIB_VERSION_CURRENT)
  34. AC_SUBST(LIB_VERSION_REVISION)
  35. AC_SUBST(LIB_VERSION_AGE)
  36. LIBSPDY_VERSION_CURRENT=0
  37. LIBSPDY_VERSION_REVISION=0
  38. LIBSPDY_VERSION_AGE=0
  39. AC_SUBST(LIBSPDY_VERSION_CURRENT)
  40. AC_SUBST(LIBSPDY_VERSION_REVISION)
  41. AC_SUBST(LIBSPDY_VERSION_AGE)
  42. if test `uname -s` = "OS/390"
  43. then
  44. # configure binaries for z/OS
  45. if test -z "$CC"
  46. then
  47. CC=`pwd`"/contrib/xcc"
  48. chmod +x $CC || true
  49. fi
  50. if test -z "$CPP"
  51. then
  52. CPP="c89 -E"
  53. fi
  54. if test -z "$CXXCPP"
  55. then
  56. CXXCPP="c++ -E -+"
  57. fi
  58. # _CCC_CCMODE=1
  59. # _C89_CCMODE=1
  60. fi
  61. # Checks for programs.
  62. AC_PROG_AWK
  63. AC_PROG_INSTALL
  64. AC_PROG_LN_S
  65. AC_PROG_MAKE_SET
  66. AC_CANONICAL_HOST
  67. AM_PROG_CC_C_O
  68. LT_INIT([win32-dll])
  69. LT_LANG([Windows Resource])
  70. PACKAGE_VERSION_MAJOR=${PACKAGE_VERSION%.*.*}
  71. PACKAGE_VERSION_MINOR=${PACKAGE_VERSION%.*}; PACKAGE_VERSION_MINOR=${PACKAGE_VERSION_MINOR#*.}
  72. PACKAGE_VERSION_SUBMINOR=${PACKAGE_VERSION#*.*.}
  73. AC_SUBST([PACKAGE_VERSION_MAJOR])
  74. AC_SUBST([PACKAGE_VERSION_MINOR])
  75. AC_SUBST([PACKAGE_VERSION_SUBMINOR])
  76. AC_CONFIG_FILES([src/microhttpd/microhttpd_dll_res.rc])
  77. MHD_LIB_CPPFLAGS=""
  78. MHD_LIB_CFLAGS=""
  79. MHD_LIB_LDFLAGS=""
  80. MHD_LIBDEPS=""
  81. AC_ARG_WITH([threads],
  82. [AC_HELP_STRING([--with-threads=LIB],[choose threading library (posix, w32, auto) [auto]])],
  83. [], [with_threads='auto'])
  84. test "x$with_threads" = "xwin32" && with_threads='w32'
  85. test "x$with_threads" = "xpthreads" && with_threads='posix'
  86. # Check for posix threads support
  87. AX_PTHREAD([HAVE_POSIX_THREADS='yes'],[HAVE_POSIX_THREADS='no'])
  88. AM_CONDITIONAL([HAVE_POSIX_THREADS],[test "x$HAVE_POSIX_THREADS" = "xyes"])
  89. # Simple check for W32 threads support
  90. AC_CHECK_HEADER([windows.h],
  91. [
  92. AC_MSG_CHECKING([for CreateThread()])
  93. AC_LINK_IFELSE(
  94. [AC_LANG_PROGRAM([#include <windows.h>], [ HANDLE h = CreateThread(NULL, 0, NULL, NULL, 0, NULL);])],
  95. [
  96. AC_MSG_RESULT([yes])
  97. HAVE_W32_THREADS='yes'
  98. ],
  99. [
  100. AC_MSG_RESULT([no])
  101. HAVE_W32_THREADS='no'
  102. ])
  103. ],
  104. [HAVE_W32_THREADS='no'])
  105. # for pkg-config
  106. MHD_LIBDEPS=""
  107. MHD_REQ_PRIVATE=''
  108. # Check system type
  109. case "$host_os" in
  110. *darwin* | *rhapsody* | *macosx*)
  111. AC_DEFINE_UNQUOTED(OSX,1,[This is an OS X system])
  112. CFLAGS="-no-cpp-precomp -fno-common $CFLAGS"
  113. ;;
  114. freebsd*)
  115. AC_DEFINE_UNQUOTED(SOMEBSD,1,[This is a BSD system])
  116. AC_DEFINE_UNQUOTED(FREEBSD,1,[This is a FreeBSD system])
  117. ;;
  118. openbsd*)
  119. AC_DEFINE_UNQUOTED(SOMEBSD,1,[This is a BSD system])
  120. AC_DEFINE_UNQUOTED(OPENBSD,1,[This is an OpenBSD system])
  121. ;;
  122. netbsd*)
  123. AC_DEFINE_UNQUOTED(SOMEBSD,1,[This is a BSD system])
  124. AC_DEFINE_UNQUOTED(NETBSD,1,[This is a NetBSD system])
  125. ;;
  126. *solaris*)
  127. AC_DEFINE_UNQUOTED(SOLARIS,1,[This is a Solaris system])
  128. AC_DEFINE_UNQUOTED(_REENTRANT,1,[Need with solaris or errno doesnt work])
  129. AC_SEARCH_LIBS(gethostbyname, nsl)
  130. AC_SEARCH_LIBS(socket, socket)
  131. ;;
  132. *arm-linux*)
  133. AC_DEFINE_UNQUOTED(LINUX,1,[This is a Linux kernel])
  134. AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets])
  135. CFLAGS="-fPIC -pipe $CFLAGS"
  136. ;;
  137. *linux*)
  138. AC_DEFINE_UNQUOTED(LINUX,1,[This is a Linux kernel])
  139. AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets])
  140. ;;
  141. *cygwin*)
  142. AC_DEFINE_UNQUOTED(CYGWIN,1,[This is a Cygwin system])
  143. os_is_windows=yes
  144. ;;
  145. *mingw*)
  146. AC_DEFINE_UNQUOTED(MINGW,1,[This is a MinGW system])
  147. AC_DEFINE_UNQUOTED(WINDOWS,1,[This is a Windows system])
  148. LIBS="$LIBS -lws2_32"
  149. AC_CHECK_HEADERS([winsock2.h ws2tcpip.h],, AC_MSG_ERROR([[Winsock2 headers are required for W32]]))
  150. AC_CACHE_CHECK([for MS lib utility], [ac_cv_use_ms_lib_tool],
  151. [[mslibcheck=`lib 2>&1`
  152. if [[ $mslibcheck = "Microsoft (R) Library Manager"* ]]; then
  153. ac_cv_use_ms_lib_tool=yes
  154. else
  155. ac_cv_use_ms_lib_tool=no
  156. fi
  157. ]])
  158. if test "x$ac_cv_use_ms_lib_tool" = "xyes"; then
  159. AC_SUBST([MS_LIB_TOOL], [[lib]])
  160. fi
  161. AC_SUBST([lt_cv_objdir])
  162. os_is_windows=yes
  163. os_is_native_w32=yes
  164. ;;
  165. *openedition*)
  166. AC_DEFINE_UNQUOTED(OS390,1,[This is a OS/390 system])
  167. ;;
  168. *)
  169. AC_MSG_WARN([Unrecognised OS $host_os])
  170. AC_DEFINE_UNQUOTED(OTHEROS,1,[Some strange OS])
  171. # You might want to find out if your OS supports shutdown on listen sockets,
  172. # and extend the switch statement; if we do not have 'HAVE_LISTEN_SHUTDOWN',
  173. # pipes are used instead to signal 'select'.
  174. # AC_DEFINE_UNQUOTED(HAVE_LISTEN_SHUTDOWN,1,[can use shutdown on listen sockets])
  175. ;;
  176. esac
  177. if test "x$with_threads" = "xposix"; then
  178. # forced posix threads
  179. if test "x$HAVE_POSIX_THREADS" = "xyes"; then
  180. USE_THREADS='posix'
  181. else
  182. if test "x$HAVE_W32_THREADS" = "xyes"; then
  183. AC_MSG_ERROR([[Posix threads are not available. Try to configure --with-threads=auto]])
  184. else
  185. AC_MSG_ERROR([[Posix threads are not available]])
  186. fi
  187. fi
  188. elif test "x$with_threads" = "xw32"; then
  189. # forced w32 threads
  190. if test "x$HAVE_W32_THREADS" = "xyes"; then
  191. USE_THREADS='w32'
  192. else
  193. if test "x$HAVE_POSIX_THREADS" = "xyes"; then
  194. AC_MSG_ERROR([[W32 threads are not available. Try to configure --with-threads=auto]])
  195. else
  196. AC_MSG_ERROR([[W32 threads are not available]])
  197. fi
  198. fi
  199. else
  200. # automatic threads lib selection
  201. if test "x$HAVE_POSIX_THREADS" = "xyes" && test "x$HAVE_W32_THREADS" = "xyes"; then
  202. if test "x$os_is_native_w32" = "xyes"; then
  203. USE_THREADS='w32'
  204. else
  205. USE_THREADS='posix'
  206. fi
  207. elif test "x$HAVE_POSIX_THREADS" = "xyes"; then
  208. USE_THREADS='posix'
  209. elif test "x$HAVE_W32_THREADS" = "xyes"; then
  210. USE_THREADS='w32'
  211. else
  212. AC_MSG_ERROR([[No threading lib is available. Cosider installing pthreads]])
  213. fi
  214. fi
  215. if test "x$USE_THREADS" = "xposix"; then
  216. CC="$PTHREAD_CC"
  217. AC_DEFINE([MHD_USE_POSIX_THREADS],[1],[define to use pthreads])
  218. MHD_LIB_CFLAGS="$MHD_LIB_CFLAGS $PTHREAD_CFLAGS"
  219. MHD_LIBDEPS="$PTHREAD_LIBS $MHD_LIBDEPS"
  220. elif test "x$USE_THREADS" = "xw32"; then
  221. AC_DEFINE([MHD_USE_W32_THREADS],[1],[define to use W32 threads])
  222. fi
  223. AM_CONDITIONAL([USE_POSIX_THREADS], [test "x$USE_THREADS" = "xposix"])
  224. AM_CONDITIONAL([USE_W32_THREADS], [test "x$USE_THREADS" = "xw32"])
  225. AM_CONDITIONAL(HAVE_W32, [test "x$os_is_native_w32" = "xyes"])
  226. w32_shared_lib_exp=no
  227. if test "x$enable_shared" = "xyes" && test "x$os_is_native_w32" = "xyes"; then
  228. if test "x$ac_cv_use_ms_lib_tool" = "xyes" || test -n "$DLLTOOL"; then
  229. w32_shared_lib_exp=yes
  230. else
  231. AC_MSG_WARN([[GNU dlltool or MS lib.exe is required for creating shared library export on W32]])
  232. AC_MSG_WARN([[Export library libmicrohttpd.lib will not be created]])
  233. fi
  234. fi
  235. AM_CONDITIONAL(W32_SHARED_LIB_EXP, [test "x$w32_shared_lib_exp" = "xyes"])
  236. AM_CONDITIONAL(USE_MS_LIB_TOOL, [test "x$ac_cv_use_ms_lib_tool" = "xyes"])
  237. # set GCC options
  238. # use '-fno-strict-aliasing', but only if the compiler
  239. # and linker can take it
  240. AX_CHECK_LINK_FLAG([-fno-strict-aliasing],
  241. [AX_APPEND_COMPILE_FLAGS([-fno-strict-aliasing])])
  242. AC_C_BIGENDIAN
  243. AC_CHECK_PROG([HAVE_CURL_BINARY],[curl],[yes],[no])
  244. AM_CONDITIONAL([HAVE_CURL_BINARY],[test "x$HAVE_CURL_BINARY" = "xyes"])
  245. AC_CHECK_PROG([HAVE_MAKEINFO_BINARY],[makeinfo],[yes],[no])
  246. AM_CONDITIONAL([HAVE_MAKEINFO_BINARY],[test "x$HAVE_MAKEINFO_BINARY" = "xyes"])
  247. AM_CONDITIONAL(W32_STATIC_LIB, [test "x$os_is_native_w32" = "xyes" && test "x$enable_static" = "xyes"])
  248. AC_ARG_ENABLE([[doc]],
  249. [AS_HELP_STRING([[--disable-doc]], [do not build any documentation])], ,
  250. [enable_doc=yes])
  251. test "x$enable_doc" = "xno" || enable_doc=yes
  252. AM_CONDITIONAL([BUILD_DOC], [test "x$enable_doc" = "xyes"])
  253. AC_ARG_ENABLE([[examples]],
  254. [AS_HELP_STRING([[--disable-examples]], [do not build any examples])], ,
  255. [enable_examples=yes])
  256. test "x$enable_examples" = "xno" || enable_examples=yes
  257. AM_CONDITIONAL([BUILD_EXAMPLES], [test "x$enable_examples" = "xyes"])
  258. AC_ARG_ENABLE([[poll]],
  259. [AS_HELP_STRING([[--enable-poll[=ARG]]], [enable poll support (yes, no, auto) [auto]])],
  260. [enable_poll=${enableval}],
  261. [enable_poll='auto']
  262. )
  263. if test "$enable_poll" != "no"; then
  264. if test "$os_is_native_w32" != "yes"; then
  265. AC_CHECK_HEADERS([poll.h],
  266. [
  267. AC_CHECK_FUNCS([poll], [have_poll='yes'], [have_poll='no'])
  268. ])
  269. else
  270. AC_MSG_CHECKING([for WSAPoll()])
  271. AC_LINK_IFELSE([
  272. AC_LANG_PROGRAM([[#include <winsock2.h>]], [[
  273. WSAPOLLFD fda[2];
  274. WSAPoll(fda, 2, 0);]])],
  275. [
  276. have_poll='yes'
  277. AC_DEFINE([HAVE_POLL],[1])
  278. ], [have_poll='no'])
  279. AC_MSG_RESULT([$have_poll])
  280. fi
  281. if test "$enable_poll" = "yes" && test "$have_poll" != "yes"; then
  282. AC_MSG_ERROR([[Support for poll was explicitly requested but cannot be enabled on this platform.]])
  283. fi
  284. enable_poll="$have_poll"
  285. fi
  286. AC_ARG_ENABLE([[epoll]],
  287. [AS_HELP_STRING([[--enable-epoll[=ARG]]], [enable epoll support (yes, no, auto) [auto]])],
  288. [enable_epoll=${enableval}],
  289. [enable_epoll='auto']
  290. )
  291. if test "$enable_epoll" != "no"; then
  292. AX_HAVE_EPOLL
  293. if test "${ax_cv_have_epoll}" = "yes"; then
  294. AC_DEFINE([EPOLL_SUPPORT],[1],[define to 1 to enable epoll support])
  295. enable_epoll='yes'
  296. else
  297. AC_DEFINE([EPOLL_SUPPORT],[0],[define to 0 to disable epoll support])
  298. if test "$enable_epoll" = "yes"; then
  299. AC_MSG_ERROR([[Support for epoll was explicitly requested but cannot be enabled on this platform.]])
  300. fi
  301. enable_epoll='no'
  302. fi
  303. fi
  304. if test "x$enable_epoll" = "xyes"; then
  305. AC_CACHE_CHECK([for epoll_create1()], [mhd_cv_have_epoll_create1], [
  306. AC_LINK_IFELSE([
  307. AC_LANG_PROGRAM([[#include <sys/epoll.h>]], [[
  308. int fd;
  309. fd = epoll_create1(EPOLL_CLOEXEC);]])],
  310. [mhd_cv_have_epoll_create1=yes],
  311. [mhd_cv_have_epoll_create1=no])])
  312. AS_IF([test "x$mhd_cv_have_epoll_create1" = "xyes"],[
  313. AC_DEFINE([[HAVE_EPOLL_CREATE1]], [[1]], [Define if you have epoll_create1 function.])])
  314. fi
  315. if test "x$HAVE_POSIX_THREADS" = "xyes"; then
  316. # Check for pthread_setname_np()
  317. SAVE_LIBS="$LIBS"
  318. SAVE_CFLAGS="$CFLAGS"
  319. LIBS="$PTHREAD_LIBS $LIBS"
  320. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  321. AC_MSG_CHECKING([[for pthread_setname_np]])
  322. AC_LINK_IFELSE(
  323. [AC_LANG_PROGRAM([[#include <pthread.h>]], [[ pthread_setname_np(pthread_self(), "name")]])],
  324. [AC_DEFINE([[HAVE_PTHREAD_SETNAME_NP]], [[1]], [Define if you have pthread_setname_np function.])
  325. AC_MSG_RESULT([[yes]])],
  326. [AC_MSG_RESULT([[no]])] )
  327. LIBS="$SAVE_LIBS"
  328. CFLAGS="$SAVE_CFLAGS"
  329. fi
  330. # Check for headers that are ALWAYS required
  331. AC_CHECK_HEADERS([fcntl.h math.h errno.h limits.h stdio.h locale.h sys/stat.h sys/types.h pthread.h],,AC_MSG_ERROR([Compiling libmicrohttpd requires standard UNIX headers files]))
  332. # Check for optional headers
  333. AC_CHECK_HEADERS([sys/types.h sys/time.h sys/msg.h netdb.h netinet/in.h netinet/tcp.h time.h sys/socket.h sys/mman.h arpa/inet.h sys/select.h search.h])
  334. AM_CONDITIONAL([HAVE_TSEARCH], [test "x$ac_cv_header_search_h" = "xyes"])
  335. AC_CHECK_MEMBER([struct sockaddr_in.sin_len],
  336. [ AC_DEFINE(HAVE_SOCKADDR_IN_SIN_LEN, 1, [Do we have sockaddr_in.sin_len?])
  337. ],
  338. [],
  339. [
  340. #ifdef HAVE_SYS_TYPES_H
  341. #include <sys/types.h>
  342. #endif
  343. #ifdef HAVE_SYS_SOCKET_H
  344. #include <sys/socket.h>
  345. #endif
  346. #ifdef HAVE_NETINET_IN_H
  347. #include <netinet/in.h>
  348. #endif
  349. ])
  350. # Check for pipe/socketpair signaling
  351. AC_MSG_CHECKING([[whether to enable signaling by socketpair]])
  352. AC_ARG_ENABLE([[socketpair]],
  353. [AS_HELP_STRING([[--enable-socketpair[=ARG]]], [disable internal singalling by pipes and use socket pair instead (yes, no, try) [no]])], ,
  354. [AS_IF([[test "x$os_is_windows" = "xyes"]], [enable_socketpair=yes], [enable_socketpair=no])]
  355. )
  356. AS_IF(
  357. [[test "x$enable_socketpair" != "xno"]],
  358. [AS_IF([[test "x$os_is_windows" = "xyes"]],
  359. [ AC_MSG_RESULT([[yes, forced on W32]]) ],
  360. [ AC_LINK_IFELSE(
  361. [ AC_LANG_PROGRAM([[
  362. #ifdef HAVE_SYS_TYPES_H
  363. #include <sys/types.h>
  364. #endif
  365. #ifdef HAVE_SYS_SOCKET_H
  366. #include <sys/socket.h>
  367. #endif
  368. ]],[[
  369. int sv[2];
  370. if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv) != 0) return 1
  371. ]])
  372. ],
  373. [ AC_MSG_RESULT([[yes, socketpair in available]]) ],
  374. [ AC_MSG_RESULT([[no, socketpair in not available]])
  375. AS_IF([[test "x$enable_socketpair" = "xyes"]], [ AC_MSG_ERROR([[socketpair signalling cannot be enabled.]]) ])
  376. ]
  377. )
  378. ]
  379. )
  380. ],
  381. [
  382. AC_MSG_RESULT([[no]])
  383. AS_IF([[test "x$os_is_windows" = "xyes"]], [ AC_MSG_ERROR([[socketpair must be enabled on W32]]) ])
  384. ]
  385. )
  386. if test "x$enable_socketpair" = "xyes"; then
  387. AC_DEFINE([[MHD_DONT_USE_PIPES]], [[1]], [Define to use pair of sockets instead of pipes for signaling])
  388. fi
  389. AC_CHECK_FUNCS_ONCE([memmem accept4])
  390. AC_MSG_CHECKING([[for gmtime_s]])
  391. AC_LINK_IFELSE(
  392. [AC_LANG_PROGRAM(
  393. [[ #include <time.h>]], [[struct tm now; time_t t; time (&t); gmtime_s (&now, &t)]])
  394. ],
  395. [
  396. AC_DEFINE([HAVE_GMTIME_S], [1], [Define to 1 if you have `gmtime_s' function (only for W32).])
  397. AC_MSG_RESULT([[yes]])
  398. ],
  399. [AC_MSG_RESULT([[no]])
  400. ])
  401. AC_CHECK_DECLS([SOCK_NONBLOCK], [AC_DEFINE([HAVE_SOCK_NONBLOCK], [1], [SOCK_NONBLOCK is defined in a socket header])], [],
  402. [
  403. #if defined HAVE_SYS_TYPES_H
  404. # include <sys/types.h>
  405. #endif
  406. #if defined HAVE_SYS_SOCKET_H
  407. # include <sys/socket.h>
  408. #elif defined HAVE_WINSOCK2_H
  409. # include <winsock2.h>
  410. #endif
  411. ])
  412. AC_SEARCH_LIBS([clock_gettime], [rt], [
  413. AC_DEFINE(HAVE_CLOCK_GETTIME, 1, [Have clock_gettime])
  414. ])
  415. # IPv6
  416. AC_MSG_CHECKING(for IPv6)
  417. AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
  418. #include <stdio.h>
  419. #if HAVE_NETINET_IN_H
  420. #include <netinet/in.h>
  421. #endif
  422. #if HAVE_SYS_SOCKET_H
  423. #include <sys/socket.h>
  424. #endif
  425. #if HAVE_WINSOCK2_H
  426. #include <winsock2.h>
  427. #endif
  428. #if HAVE_WS2TCPIP_H
  429. #include <ws2tcpip.h>
  430. #endif
  431. ]], [[
  432. int af=AF_INET6;
  433. int pf=PF_INET6;
  434. struct sockaddr_in6 sa;
  435. printf("%d %d %p\n", af, pf, &sa);
  436. ]])],[
  437. have_inet6=yes;
  438. AC_DEFINE([HAVE_INET6], [1], [Provides IPv6 headers])
  439. ],[
  440. have_inet6=no
  441. ])
  442. AC_MSG_RESULT($have_inet6)
  443. # TCP_CORK and TCP_NOPUSH
  444. AC_CHECK_DECLS([TCP_CORK, TCP_NOPUSH], [], [], [[#include <netinet/tcp.h>]])
  445. HIDDEN_VISIBILITY_CFLAGS=""
  446. case "$host" in
  447. *-*-mingw*)
  448. dnl on mingw32 we do -fvisibility=hidden and __declspec(dllexport)
  449. AC_DEFINE([_MHD_EXTERN], [__attribute__((visibility("default"))) __declspec(dllexport) extern],
  450. [defines how to decorate public symbols while building])
  451. HIDDEN_VISIBILITY_CFLAGS="-fvisibility=hidden"
  452. ;;
  453. *)
  454. dnl on other compilers, check if we can do -fvisibility=hidden
  455. AX_CHECK_LINK_FLAG([-fvisibility=hidden],
  456. [AX_CHECK_COMPILE_FLAG([-fvisibility=hidden],
  457. [AC_DEFINE([_MHD_EXTERN], [__attribute__((visibility("default"))) extern],
  458. [defines how to decorate public symbols while building])
  459. HIDDEN_VISIBILITY_CFLAGS="-fvisibility=hidden"])])
  460. ;;
  461. esac
  462. AC_SUBST(HIDDEN_VISIBILITY_CFLAGS)
  463. # libcurl (required for testing)
  464. AC_ARG_ENABLE([curl],
  465. [AS_HELP_STRING([--disable-curl],[disable cURL based testcases])],
  466. [enable_curl=${enableval}])
  467. curl=0
  468. if test "$enable_curl" != "no"
  469. then
  470. LIBCURL_CHECK_CONFIG([yes],[7.16.4],[enable_curl=yes],
  471. [
  472. if test "x$enable_curl" = "xyes"; then
  473. AC_MSG_WARN([[cURL-based tests cannot be enabled because libcurl is missing]])
  474. fi
  475. enable_curl=no
  476. ])
  477. fi
  478. if test "$enable_curl" != "no"
  479. then
  480. # Lib cURL & cURL - OpenSSL versions
  481. AC_DEFINE([MHD_REQ_CURL_VERSION], ["7.16.4"], [required cURL version to run tests])
  482. AC_DEFINE([MHD_REQ_CURL_OPENSSL_VERSION], ["0.9.8"], [required cURL SSL version to run tests])
  483. AC_DEFINE([MHD_REQ_CURL_GNUTLS_VERSION], ["2.8.6"], [gnuTLS lib version - used in conjunction with cURL])
  484. AC_DEFINE([MHD_REQ_CURL_NSS_VERSION], ["3.12.0"], [NSS lib version - used in conjunction with cURL])
  485. fi
  486. AM_CONDITIONAL([HAVE_CURL], [test "x$enable_curl" = "xyes"])
  487. AC_CHECK_LIB([[magic]], [[magic_open]],
  488. [AC_CHECK_HEADERS([magic.h],
  489. AM_CONDITIONAL(HAVE_MAGIC, true),
  490. AM_CONDITIONAL(HAVE_MAGIC, false))],
  491. AM_CONDITIONAL(HAVE_MAGIC, false))
  492. # optional: libmicrospdy support. Enabled by default if not on W32
  493. AC_ARG_ENABLE([spdy],
  494. AS_HELP_STRING([--enable-spdy],
  495. [enable build libmicrospdy (yes, no, auto) [auto]]),
  496. [enable_spdy=${enableval}],
  497. [ AS_IF([[test "x$os_is_windows" = "xyes"]], [enable_spdy=no]) ])
  498. if test "$enable_spdy" != "no"
  499. then
  500. AX_CHECK_OPENSSL([ have_openssl=yes ],[ have_openssl=no ])
  501. if test "x$have_openssl" = "xyes"
  502. then
  503. # check OpenSSL headers
  504. SAVE_CPP_FLAGS="$CPPFLAGS"
  505. CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS"
  506. AC_CHECK_HEADERS([openssl/evp.h openssl/rsa.h openssl/rand.h openssl/err.h openssl/sha.h openssl/pem.h openssl/engine.h], [ have_openssl=yes ],[ have_openssl=no ])
  507. if test "x$have_openssl" = "xyes"
  508. then
  509. # check OpenSSL libs
  510. SAVE_LIBS="$LIBS"
  511. SAVE_LD_FLAGS="$LDFLAGS"
  512. LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS"
  513. LIBS="$OPENSSL_LIBS $LIBS"
  514. AC_CHECK_FUNC([SSL_CTX_set_next_protos_advertised_cb],
  515. [
  516. AC_CHECK_FUNC([SSL_library_init], [ have_openssl=yes ],[ have_openssl=no ])
  517. ],[ have_openssl=no ])
  518. LIBS="$SAVE_LIBS"
  519. LDFLAGS="$SAVE_LD_FLAGS"
  520. fi
  521. CPPFLAGS="$SAVE_CPP_FLAGS"
  522. fi
  523. if test "x$have_openssl" = "xyes"
  524. then
  525. enable_spdy=yes
  526. else
  527. AS_IF([[test "x$enable_spdy" = "xyes" ]], [AC_MSG_ERROR([[libmicrospdy cannot be enabled without OpenSSL.]])])
  528. have_openssl=no
  529. enable_spdy=no
  530. fi
  531. else
  532. # OpenSSL is used only for libmicrospdy
  533. have_openssl=no
  534. fi
  535. AM_CONDITIONAL([HAVE_OPENSSL], [test "x$have_openssl" = "xyes"])
  536. if test "$enable_spdy" = "yes"
  537. then
  538. AC_DEFINE([SPDY_SUPPORT],[1],[include libmicrospdy support])
  539. else
  540. AC_DEFINE([SPDY_SUPPORT],[0],[disable libmicrospdy support])
  541. fi
  542. AM_CONDITIONAL(ENABLE_SPDY, [test "x$enable_spdy" != "xno"])
  543. AC_MSG_CHECKING(whether we have OpenSSL and thus can support libmicrospdy)
  544. AC_MSG_RESULT($enable_spdy)
  545. # for pkg-config
  546. SPDY_LIBDEPS="$OPENSSL_LIBS"
  547. SPDY_LIB_LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS"
  548. SPDY_LIB_CFLAGS="$CFLAGS"
  549. SPDY_LIB_CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS"
  550. AC_SUBST(SPDY_LIB_LDFLAGS)
  551. AC_SUBST(SPDY_LIB_CFLAGS)
  552. AC_SUBST(SPDY_LIB_CPPFLAGS)
  553. # for pkg-config
  554. AC_SUBST(SPDY_LIBDEPS)
  555. AC_CHECK_HEADERS([spdylay/spdylay.h], [ have_spdylay="yes" ], [have_spdylay="no"])
  556. AM_CONDITIONAL(HAVE_SPDYLAY, [test "x$have_spdylay" = "xyes"])
  557. # large file support (> 4 GB)
  558. AC_SYS_LARGEFILE
  559. AC_FUNC_FSEEKO
  560. # optional: have error messages ?
  561. AC_MSG_CHECKING(whether to generate error messages)
  562. AC_ARG_ENABLE([messages],
  563. [AS_HELP_STRING([--disable-messages],
  564. [disable MHD error messages])],
  565. [enable_messages=${enableval}],
  566. [enable_messages=yes])
  567. AC_MSG_RESULT($enable_messages)
  568. if test "$enable_messages" = "yes"
  569. then
  570. AC_DEFINE([HAVE_MESSAGES],[1],[Include error messages])
  571. else
  572. AC_DEFINE([HAVE_MESSAGES],[0],[Disable error messages])
  573. fi
  574. # optional: have postprocessor?
  575. AC_MSG_CHECKING(whether to enable postprocessor)
  576. AC_ARG_ENABLE([postprocessor],
  577. [AS_HELP_STRING([--disable-postprocessor],
  578. [disable MHD PostProcessor functionality])],
  579. [enable_postprocessor=${enableval}],
  580. [enable_postprocessor=yes])
  581. test "x$enable_postprocessor" = "xno" || enable_postprocessor=yes
  582. AC_MSG_RESULT([[$enable_postprocessor]])
  583. AM_CONDITIONAL([HAVE_POSTPROCESSOR],test "x$enable_postprocessor" != "xno")
  584. if test "x$enable_postprocessor" != "xno"
  585. then
  586. AC_DEFINE([HAVE_POSTPROCESSOR],[1],[define to 1 if MHD was build with postprocessor.c])
  587. fi
  588. # optional: have zzuf, socat?
  589. AC_CHECK_PROG([have_zzuf],[zzuf], [yes], [no])
  590. AC_CHECK_PROG([have_socat],[socat], [yes], [no])
  591. AM_CONDITIONAL([HAVE_ZZUF], [test "x$have_zzuf" = "xyes"])
  592. AM_CONDITIONAL([HAVE_SOCAT], [test "x$have_socat" = "xyes"])
  593. # libgcrypt linkage: required for HTTPS support
  594. AM_PATH_LIBGCRYPT([1.2.2], [have_gcrypt=yes], [have_gcrypt=no])
  595. if test "x$have_gcrypt" = "xyes"
  596. then
  597. SAVE_CFLAGS="$CFLAGS"
  598. CFLAGS="$CFLAGS $LIBGCRYPT_CFLAGS"
  599. # LIBGCRYPT_CFLAGS can be actually a CPPFLAGS, so check them both
  600. SAVE_CPPFLAGS="$CPPFLAGS"
  601. CPPFLAGS="$CPPFLAGS $LIBGCRYPT_CFLAGS"
  602. AC_CHECK_HEADERS([gcrypt.h], [], [have_gcrypt=no])
  603. CFLAGS="$SAVE_CFLAGS"
  604. CPPFLAGS="$SAVE_CPPFLAGS"
  605. fi
  606. # gnutls
  607. GNUTLS_CPPFLAGS=""
  608. GNUTLS_LDFLAGS=""
  609. have_gnutls=no
  610. have_gnutls_sni=no
  611. have_gnutls_pkgcfg=no
  612. AC_MSG_CHECKING([[how to find GnuTLS library]])
  613. AC_ARG_WITH([[gnutls]],
  614. [AC_HELP_STRING([[--with-gnutls[=PFX]]],[use GnuTLS for HTTPS support, optional PFX overrides pkg-config data for GnuTLS headers (PFX/include) and libs (PFX/lib)])],
  615. [
  616. case $with_gnutls in
  617. no)
  618. AC_MSG_RESULT([[GnuTLS disabled]])
  619. ;;
  620. yes)
  621. AC_MSG_RESULT([[automatically, forced]])
  622. ;;
  623. *)
  624. AC_MSG_RESULT([[-I$with_gnutls/include -L$with_gnutls/lib -lgnutls]])
  625. SAVE_LDFLAGS="$LDFLAGS"
  626. SAVE_CPPFLAGS="$CPPFLAGS"
  627. LDFLAGS="-L$with_gnutls/lib $LDFLAGS"
  628. CPPFLAGS="-I$with_gnutls/include $CPPFLAGS"
  629. have_gnutls_pkgcfg=no
  630. AC_CHECK_HEADERS([gnutls/gnutls.h],
  631. [AC_CHECK_LIB([gnutls], [gnutls_priority_set],
  632. [
  633. GNUTLS_CPPFLAGS="-I$with_gnutls/include"
  634. GNUTLS_LDFLAGS="-L$with_gnutls/lib"
  635. GNUTLS_LIBS="-lgnutls"
  636. AC_CHECK_LIB([gnutls], [gnutls_load_file], [AC_CHECK_LIB([gnutls], [gnutls_privkey_import_x509_raw], [have_gnutls_sni=yes])])
  637. have_gnutls=yes
  638. ])])
  639. AS_IF([test "x$have_gnutls" != "xyes"], [AC_MSG_ERROR([can't find usable libgnutls at specified prefix $with_gnutls])])
  640. LDFLAGS="$SAVE_LDFLAGS"
  641. CPPFLAGS="$SAVE_CPPFLAGS"
  642. ;;
  643. esac
  644. ],
  645. [AC_MSG_RESULT([[automatically]])
  646. ])
  647. AS_IF([test "x$with_gnutls" != "xno" && test "x$have_gnutls" != "xyes"],
  648. [
  649. PKG_CHECK_MODULES(GNUTLS, [[gnutls]],
  650. [
  651. have_gnutls_pkgcfg='yes'
  652. SAVE_CPPFLAGS="$CPPFLAGS"
  653. SAVE_CFLAGS="$CFLAGS"
  654. SAVE_LDFLAGS="$LDFLAGS"
  655. SAVE_LIBS="$LIBS"
  656. CPPFLAGS="$GNUTLS_CFLAGS $CPPFLAGS"
  657. CFLAGS="$GNUTLS_CFLAGS $CFLAGS"
  658. LDFLAGS="$GNUTLS_LIBS $LDFLAGS"
  659. LIBS="$LIBS $GNUTLS_LIBS"
  660. AC_MSG_CHECKING([[whether GnuTLS is usable]])
  661. AC_LINK_IFELSE([
  662. AC_LANG_PROGRAM([[#include <gnutls/gnutls.h>]], [[
  663. gnutls_session_t session;
  664. gnutls_priority_t priorities;
  665. gnutls_global_init();
  666. gnutls_priority_init(&priorities, "NORMAL", NULL);
  667. gnutls_init(&session, GNUTLS_SERVER);
  668. gnutls_priority_set(session, priorities);
  669. ]])],
  670. [
  671. AC_MSG_RESULT([[yes]])
  672. have_gnutls=yes
  673. GNUTLS_CPPLAGS="$GNUTLS_CFLAGS"
  674. GNUTLS_LDFLAGS="$GNUTLS_LIBS"
  675. AC_MSG_CHECKING([[for gnutls_privkey_import_x509_raw()]])
  676. AC_LINK_IFELSE([
  677. AC_LANG_PROGRAM([[#include <gnutls/gnutls.h>]], [[
  678. gnutls_datum_t data;
  679. gnutls_privkey_t key;
  680. gnutls_load_file("key.pem", &data);
  681. gnutls_privkey_import_x509_raw(key, &data, GNUTLS_X509_FMT_PEM, NULL, 0);
  682. gnutls_free(data.data);
  683. ]])], [[have_gnutls_sni=yes]], [[have_gnutls_sni=no]])
  684. AC_MSG_RESULT([[$have_gnutls_sni]])
  685. ],
  686. [
  687. AC_MSG_RESULT([[no]])
  688. have_gnutls=no
  689. ])
  690. AS_IF([test "x$have_gnutls" != "xyes"], [AC_MSG_WARN([pkg-config reports that GnuTLS is present, but GnuTLS can't be used])])
  691. CPPFLAGS="$SAVE_CPPFLAGS"
  692. CFLAGS="$SAVE_CFLAGS"
  693. LDFLAGS="$SAVE_LDFLAGS"
  694. LIBS="$SAVE_LIBS"
  695. ],
  696. [
  697. have_gnutls_pkgcfg='no'
  698. AC_CHECK_HEADERS([gnutls/gnutls.h],
  699. [AC_CHECK_LIB([gnutls], [gnutls_priority_set],
  700. [
  701. GNUTLS_LIBS="-lgnutls"
  702. AC_CHECK_LIB([gnutls], [gnutls_load_file], [AC_CHECK_LIB([gnutls], [gnutls_privkey_import_x509_raw], [have_gnutls_sni=yes])])
  703. have_gnutls=yes
  704. ])])
  705. ])
  706. ])
  707. AS_IF([test "x$have_gnutls" != "xyes" && test "x$with_gnutls" = "xyes"], [AC_MSG_ERROR([[can't find usable libgnutls]])])
  708. AM_CONDITIONAL(HAVE_GNUTLS, test "x$have_gnutls" = "xyes")
  709. AM_CONDITIONAL([HAVE_GNUTLS_SNI], [test "x$have_gnutls_sni" = "xyes"])
  710. AC_SUBST([GNUTLS_CPPFLAGS])
  711. AC_SUBST([GNUTLS_CFLAGS])
  712. AC_SUBST([GNUTLS_LDFLAGS])
  713. AC_SUBST([GNUTLS_LIBS])
  714. # optional: HTTPS support. Enabled by default
  715. AC_MSG_CHECKING(whether to support HTTPS)
  716. AC_ARG_ENABLE([https],
  717. [AS_HELP_STRING([--enable-https],
  718. [enable HTTPS support (yes, no, auto)[auto]])],
  719. [enable_https=${enableval}])
  720. if test "x$enable_https" != "xno"
  721. then
  722. AS_IF([test "x$have_gnutls" = "xyes" && test "x$have_gcrypt" = "xyes"], [
  723. AC_DEFINE([HTTPS_SUPPORT],[1],[include HTTPS support])
  724. MHD_LIB_CPPFLAGS="$MHD_LIB_CPPFLAGS $LIBGCRYPT_CFLAGS $GNUTLS_CPPFLAGS"
  725. MHD_LIB_CFLAGS="$MHD_LIB_CFLAGS $LIBGCRYPT_CFLAGS $GNUTLS_CFLAGS"
  726. MHD_LIB_LDFLAGS="$MHD_LIB_LDFLAGS $GNUTLS_LDFLAGS"
  727. MHD_LIBDEPS="$GNUTLS_LIBS $LIBGCRYPT_LIBS $MHD_LIBDEPS"
  728. enable_https=yes
  729. MSG_HTTPS="yes (using libgnutls and libgcrypt)"
  730. ], [
  731. AS_IF([test "x$have_gnutls" = "xyes"], [crypt_missing="libgrypt"],
  732. [test "x$have_gcrypt" = "xyes"], [crypt_missing="libgnutls"],
  733. [crypt_missing="libgrypt and libgnutls"])
  734. AS_IF([[test "x$enable_https" = "xyes" ]], [AC_MSG_ERROR([[HTTPS support cannot be enabled without $crypt_missing.]])])
  735. AC_DEFINE([HTTPS_SUPPORT],[0],[no libgcrypt or libgnutls])
  736. enable_https=no
  737. MSG_HTTPS="no (lacking $crypt_missing)"
  738. ])
  739. else
  740. AC_DEFINE([HTTPS_SUPPORT],[0],[disable HTTPS support])
  741. MSG_HTTPS="no (disabled)"
  742. fi
  743. AC_MSG_RESULT([$MSG_HTTPS])
  744. AM_CONDITIONAL([ENABLE_HTTPS], [test "x$enable_https" = "xyes"])
  745. # optional: HTTP Basic Auth support. Enabled by default
  746. AC_MSG_CHECKING(whether to support HTTP basic authentication)
  747. AC_ARG_ENABLE([bauth],
  748. AS_HELP_STRING([--disable-bauth],
  749. [disable HTTP basic Auth support]),
  750. [enable_bauth=${enableval}],
  751. [enable_bauth=yes])
  752. if test "x$enable_bauth" != "xno"
  753. then
  754. enable_bauth=yes
  755. AC_DEFINE([BAUTH_SUPPORT],[1],[include basic Auth support])
  756. else
  757. AC_DEFINE([BAUTH_SUPPORT],[0],[disable basic Auth support])
  758. fi
  759. AC_MSG_RESULT($enable_bauth)
  760. AM_CONDITIONAL(ENABLE_BAUTH, [test "x$enable_bauth" != "xno"])
  761. # optional: HTTP Digest Auth support. Enabled by default
  762. AC_MSG_CHECKING(whether to support HTTP digest authentication)
  763. AC_ARG_ENABLE([dauth],
  764. AS_HELP_STRING([--disable-dauth],
  765. [disable HTTP basic and digest Auth support]),
  766. [enable_dauth=${enableval}],
  767. [enable_dauth=yes])
  768. if test "x$enable_dauth" != "xno"
  769. then
  770. enable_dauth=yes
  771. AC_DEFINE([DAUTH_SUPPORT],[1],[include digest Auth support])
  772. else
  773. AC_DEFINE([DAUTH_SUPPORT],[0],[disable digest Auth support])
  774. fi
  775. AC_MSG_RESULT($enable_dauth)
  776. AM_CONDITIONAL(ENABLE_DAUTH, [test "x$enable_dauth" != "xno"])
  777. MHD_LIB_LDFLAGS="$MHD_LIB_LDFLAGS -export-dynamic -no-undefined"
  778. # gcov compilation
  779. AC_MSG_CHECKING(whether to compile with support for code coverage analysis)
  780. AC_ARG_ENABLE([coverage],
  781. AS_HELP_STRING([--enable-coverage],
  782. [compile the library with code coverage support]),
  783. [use_gcov=${enableval}],
  784. [use_gcov=no])
  785. AC_MSG_RESULT($use_gcov)
  786. AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"])
  787. AX_COUNT_CPUS
  788. AC_SUBST([CPU_COUNT])
  789. AC_SUBST(MHD_LIB_CPPFLAGS)
  790. AC_SUBST(MHD_LIB_CFLAGS)
  791. AC_SUBST(MHD_LIB_LDFLAGS)
  792. # for pkg-config
  793. AS_IF([[test "x$enable_https" = "xyes" && test "x$have_gnutls_pkgcfg" = "xyes" ]],
  794. [ # remove GnuTLS from private libs in .pc file as it defined in Requires.private
  795. MHD_REQ_PRIVATE='gnutls'
  796. MHD_LIBDEPS_PKGCFG="${MHD_LIBDEPS//$GNUTLS_LIBS/}"
  797. ],
  798. [
  799. MHD_REQ_PRIVATE=''
  800. MHD_LIBDEPS_PKGCFG="$MHD_LIBDEPS"
  801. ])
  802. AC_SUBST([MHD_REQ_PRIVATE])
  803. AC_SUBST([MHD_LIBDEPS_PKGCFG])
  804. AC_SUBST(MHD_LIBDEPS)
  805. AC_SUBST(CPPFLAGS)
  806. AC_SUBST(LIBS)
  807. AC_SUBST(LDFLAGS)
  808. AC_CONFIG_FILES([
  809. libmicrohttpd.pc
  810. libmicrospdy.pc
  811. w32/VS2013/microhttpd_dll_res_vc.rc
  812. Makefile
  813. contrib/Makefile
  814. doc/Makefile
  815. doc/doxygen/Makefile
  816. doc/examples/Makefile
  817. m4/Makefile
  818. src/Makefile
  819. src/include/Makefile
  820. src/platform/Makefile
  821. src/microhttpd/Makefile
  822. src/microspdy/Makefile
  823. src/spdy2http/Makefile
  824. src/examples/Makefile
  825. src/testcurl/Makefile
  826. src/testcurl/https/Makefile
  827. src/testspdy/Makefile
  828. src/testzzuf/Makefile])
  829. AC_OUTPUT
  830. # Finally: summary
  831. if test "x$enable_curl" != "xyes"; then
  832. MSG_CURL="no, many unit tests will not run"
  833. else
  834. MSG_CURL="yes"
  835. fi
  836. AC_MSG_NOTICE([Configuration Summary:
  837. Operating System: ${host_os}
  838. Threading lib: ${USE_THREADS}
  839. libcurl (testing): ${MSG_CURL}
  840. Target directory: ${prefix}
  841. Messages: ${enable_messages}
  842. Basic auth.: ${enable_bauth}
  843. Digest auth.: ${enable_dauth}
  844. Postproc: ${enable_postprocessor}
  845. HTTPS support: ${MSG_HTTPS}
  846. poll support: ${enable_poll=no}
  847. epoll support: ${enable_epoll=no}
  848. build docs: ${enable_doc}
  849. build examples: ${enable_examples}
  850. libmicrospdy: ${enable_spdy}
  851. spdylay (testing): ${have_spdylay}
  852. ])
  853. if test "x$enable_https" = "xyes"
  854. then
  855. AC_MSG_NOTICE([HTTPS subsystem configuration:
  856. License : LGPL only
  857. ])
  858. else
  859. AC_MSG_NOTICE([
  860. License : LGPL or eCos
  861. ])
  862. fi
  863. if test "x$enable_bauth" != "xyes" -o \
  864. "x$enable_dauth" != "xyes" -o \
  865. "x$enable_postprocessor" != "xyes"
  866. then
  867. AC_MSG_NOTICE([WARNING: This will be a custom build with missing symbols. Do NOT use this build in a distribution. Building with these kinds of configure options is only for custom builds for embedded systems.])
  868. fi