< prev index next >

make/autoconf/lib-bundled.m4

Print this page

        

@@ -181,10 +181,21 @@
     AC_MSG_RESULT([bundled])
   elif test "x${with_zlib}" = "xsystem"; then
     if test "x${ZLIB_FOUND}" = "xyes"; then
       USE_EXTERNAL_LIBZ=true
       AC_MSG_RESULT([system])
+
+      AC_MSG_CHECKING([for system zlib functionality])
+      AC_COMPILE_IFELSE(
+          [AC_LANG_PROGRAM([[#include "zlib.h"]],
+              [[inflateValidate(NULL, 0);]])],
+          [AC_MSG_RESULT([ok])],
+          [
+              AC_MSG_RESULT([not ok])
+              AC_MSG_ERROR([System zlib not working or not up to date (at least version 1.2.9 required)])
+          ]
+      )
     else
       AC_MSG_RESULT([system not found])
       AC_MSG_ERROR([--with-zlib=system specified, but no zlib found!])
     fi
   else
< prev index next >