From e59427a62cdd93ac8b18396d19f6dc74e979df95 Mon Sep 17 00:00:00 2001 From: "kenton@google.com" Date: Thu, 16 Apr 2009 22:30:56 +0000 Subject: Commit Brian Olson's gzip stream implementations. --- configure.ac | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 6015281b..2824960b 100644 --- a/configure.ac +++ b/configure.ac @@ -15,6 +15,11 @@ AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) AM_INIT_AUTOMAKE +AC_ARG_WITH([zlib], + [AS_HELP_STRING([--with-zlib], + [include classes for streaming compressed data in and out @<:@default=check@:>@])], + [],[with_zlib=check]) + # Checks for programs. AC_PROG_CC AC_PROG_CXX @@ -38,6 +43,16 @@ AC_FUNC_MEMCMP AC_FUNC_STRTOD AC_CHECK_FUNCS([ftruncate memset mkdir strchr strerror strtol]) +HAVE_ZLIB=0 +AS_IF([test "$with_zlib" != no], + [AC_SEARCH_LIBS([zlibVersion], [z], + [AC_DEFINE([HAVE_ZLIB], [1], [Enable classes using zlib compression.]) + HAVE_ZLIB=1], + [if test "$with_zlib" != check; then + AC_MSG_FAILURE([--with-zlib was given, but test for zlib failed]) + fi])]) +AM_CONDITIONAL([HAVE_ZLIB], [test $HAVE_ZLIB = 1]) + ACX_PTHREAD AC_CXX_STL_HASH -- cgit v1.2.3