aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-05-21 12:35:28 +0000
committerChristian Grothoff <christian@grothoff.org>2013-05-21 12:35:28 +0000
commit05d1a633b17b530fd95b20b11f08685d1c91a1ce (patch)
tree54bd5c0b515a65b5c552d25408dcc8ee02385d32
parentcfea15fe53e1d84d38de88651f31122de6369143 (diff)
downloadlibmicrohttpd-05d1a633b17b530fd95b20b11f08685d1c91a1ce.tar.gz
libmicrohttpd-05d1a633b17b530fd95b20b11f08685d1c91a1ce.zip
improving build system to tolerate missing libraries for libmicrospdy
-rw-r--r--ChangeLog5
-rw-r--r--configure.ac22
-rw-r--r--src/Makefile.am8
3 files changed, 32 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 1f3176a1..49c5cfb2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
1Tue May 21 14:34:36 CEST 2013
2 Improving configure tests for OpenSSL and spdylay to
3 avoid build errors in libmicrospdy code if those libraries
4 are not present. -CG
5
1Mon May 20 12:29:35 CEST 2013 6Mon May 20 12:29:35 CEST 2013
2 Added MHD_CONNECTION_INFO_CONNECTION_FD to allow clients 7 Added MHD_CONNECTION_INFO_CONNECTION_FD to allow clients
3 direct access to connection socket; useful for COMET 8 direct access to connection socket; useful for COMET
diff --git a/configure.ac b/configure.ac
index 6f2a7851..c4380511 100644
--- a/configure.ac
+++ b/configure.ac
@@ -279,20 +279,38 @@ AC_ARG_ENABLE([spdy],
279 [disable libmicrospdy]), 279 [disable libmicrospdy]),
280 [enable_spdy=${enableval}], 280 [enable_spdy=${enableval}],
281 [enable_spdy=yes]) 281 [enable_spdy=yes])
282AC_MSG_RESULT($enable_spdy)
283
284if test "$enable_spdy" = "yes"
285then
286 AC_CHECK_HEADERS([openssl/err.h],
287 [AM_CONDITIONAL(HAVE_OPENSSL, true)
288 enable_spdy="yes"],
289 [AM_CONDITIONAL(HAVE_OPENSSL, false)
290 enable_spdy="no"])
291fi
292
282if test "$enable_spdy" = "yes" 293if test "$enable_spdy" = "yes"
283then 294then
284 AC_DEFINE([SPDY_SUPPORT],[1],[include libmicrospdy support]) 295 AC_DEFINE([SPDY_SUPPORT],[1],[include libmicrospdy support])
285else 296else
286 AC_DEFINE([SPDY_SUPPORT],[0],[disable libmicrospdy support]) 297 AC_DEFINE([SPDY_SUPPORT],[0],[disable libmicrospdy support])
287fi 298fi
288AC_MSG_RESULT($enable_spdy)
289AM_CONDITIONAL(ENABLE_SPDY, [test "x$enable_spdy" != "xno"]) 299AM_CONDITIONAL(ENABLE_SPDY, [test "x$enable_spdy" != "xno"])
300AC_MSG_CHECKING(whether we have OpenSSL and thus can support libmicrospdy)
301AC_MSG_RESULT($enable_spdy)
290 302
291spdy_OPENSSL 303spdy_OPENSSL
292# for pkg-config 304# for pkg-config
293SPDY_LIBDEPS="" 305SPDY_LIBDEPS=""
294 306
295 307
308AC_CHECK_HEADERS([spdylay/spdylay.h],
309 [AM_CONDITIONAL(HAVE_SPDYLAY, true)
310 have_spdylay="yes"],
311 [AM_CONDITIONAL(HAVE_SPDYLAY, false)
312 have_spdylay="no"])
313
296AC_SUBST(SPDY_LIB_LDFLAGS) 314AC_SUBST(SPDY_LIB_LDFLAGS)
297# for pkg-config 315# for pkg-config
298AC_SUBST(SPDY_LIBDEPS) 316AC_SUBST(SPDY_LIBDEPS)
@@ -529,6 +547,8 @@ AC_MSG_NOTICE([Configuration Summary:
529 Digest auth.: ${enable_dauth} 547 Digest auth.: ${enable_dauth}
530 Postproc: ${enable_postprocessor} 548 Postproc: ${enable_postprocessor}
531 HTTPS support: ${enable_https} 549 HTTPS support: ${enable_https}
550 libmicrospdy: ${enable_spdy}
551 spdylay (testing): ${have_spdylay}
532]) 552])
533 553
534if test "x$enable_https" = "xyes" 554if test "x$enable_https" = "xyes"
diff --git a/src/Makefile.am b/src/Makefile.am
index dfd93abe..b26045f1 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -7,8 +7,12 @@ endif
7endif 7endif
8endif 8endif
9if ENABLE_SPDY 9if ENABLE_SPDY
10# fixme: should test for spdylay before building testspdy! 10if HAVE_OPENSSL
11microspdy = microspdy spdy2http testspdy 11microspdy = microspdy spdy2http
12if HAVE_SPDYLAY
13microspdy += testspdy
14endif
15endif
12endif 16endif
13 17
14SUBDIRS = include microhttpd $(microspdy) examples $(curltests) $(zzuftests) . 18SUBDIRS = include microhttpd $(microspdy) examples $(curltests) $(zzuftests) .