mirror of https://github.com/aria2/aria2
Check zlib availability usin AC_CHECK_LIB
This is workaround for zlib 1.2.3 which does not come with pkg-config file.pull/89/head
parent
1b920e4011
commit
774e1b8a10
11
configure.ac
11
configure.ac
|
@ -110,16 +110,21 @@ fi
|
||||||
if test "x$with_libz" = "xyes"; then
|
if test "x$with_libz" = "xyes"; then
|
||||||
PKG_CHECK_MODULES([ZLIB], [zlib >= 1.2.3], [have_zlib=yes], [have_zlib=no])
|
PKG_CHECK_MODULES([ZLIB], [zlib >= 1.2.3], [have_zlib=yes], [have_zlib=no])
|
||||||
if test "x$have_zlib" = "xyes"; then
|
if test "x$have_zlib" = "xyes"; then
|
||||||
AC_DEFINE([HAVE_ZLIB], [1], [Define to 1 if you have zlib.])
|
|
||||||
LIBS="$ZLIB_LIBS $LIBS"
|
LIBS="$ZLIB_LIBS $LIBS"
|
||||||
CPPFLAGS="$ZLIB_CFLAGS $CPPFLAGS"
|
CPPFLAGS="$ZLIB_CFLAGS $CPPFLAGS"
|
||||||
AC_CHECK_FUNCS([gzbuffer gzsetparams])
|
|
||||||
else
|
else
|
||||||
AC_MSG_WARN([$ZLIB_PKG_ERRORS])
|
AC_MSG_WARN([$ZLIB_PKG_ERRORS])
|
||||||
if test "x$with_libz_requested" = "xyes"; then
|
AC_CHECK_LIB([z], [zlibVersion], [have_zlib=yes], [have_zlib=no])
|
||||||
|
if test "x$have_zlib" = "xyes"; then
|
||||||
|
LIBS="-lz $LIBS"
|
||||||
|
elif test "x$with_libz_requested" = "xyes"; then
|
||||||
ARIA2_DEP_NOT_MET([libz])
|
ARIA2_DEP_NOT_MET([libz])
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if test "x$have_zlib" = "xyes"; then
|
||||||
|
AC_DEFINE([HAVE_ZLIB], [1], [Define to 1 if you have zlib.])
|
||||||
|
AC_CHECK_FUNCS([gzbuffer gzsetparams])
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$with_libuv" = "xyes"; then
|
if test "x$with_libuv" = "xyes"; then
|
||||||
|
|
Loading…
Reference in New Issue