+2009-11-24 Joel Brobecker <brobecker@adacore.com>
+
+ * acinclude.m4: Include ../config/zlib.m4.
+ * configure.ac: Use AM_ZLIB to check for zlib support.
+ * configure: Regenerate.
+
2009-11-24 Joel Brobecker <brobecker@adacore.com>
* breakpoint.c (expand_line_sal_maybe): Adjust adjust the SAL
dnl For AM_LANGINFO_CODESET.
sinclude([../config/codeset.m4])
+sinclude([../config/zlib.m4])
+
#
# Sometimes the native compiler is a bogus stub for gcc or /usr/ucb/cc. This
# makes configure think it's cross compiling. If --target wasn't used, then
enable_profiling
with_pkgversion
with_bugurl
+with_zlib
with_libiconv_prefix
with_system_readline
with_expat
library
--with-pkgversion=PKG Use PKG in the version string in place of "GDB"
--with-bugurl=URL Direct users to URL to report a bug
+ --with-zlib include zlib support (auto/yes/no) default=auto
--with-libiconv-prefix=DIR
search for libiconv in DIR/include and DIR/lib
--with-system-readline use installed readline library
# Link in zlib if we can. This allows us to read compressed debug sections.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing zlibVersion" >&5
+
+ # See if the user specified whether he wants zlib support or not.
+
+# Check whether --with-zlib was given.
+if test "${with_zlib+set}" = set; then :
+ withval=$with_zlib;
+else
+ with_zlib=auto
+fi
+
+
+ if test "$with_zlib" != "no"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing zlibVersion" >&5
$as_echo_n "checking for library containing zlibVersion... " >&6; }
if test "${ac_cv_search_zlibVersion+set}" = set; then :
$as_echo_n "(cached) " >&6
fi
+ if test "$with_zlib" = "yes" -a "$ac_cv_header_zlib_h" != "yes"; then
+ as_fn_error "zlib (libz) library was explicitly requested but not found" "$LINENO" 5
+ fi
+ fi
+
# On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlgetmodinfo" >&5
AC_SEARCH_LIBS(socketpair, socket)
# Link in zlib if we can. This allows us to read compressed debug sections.
-AC_SEARCH_LIBS(zlibVersion, z, [AC_CHECK_HEADERS(zlib.h)])
+AM_ZLIB
# On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
AC_SEARCH_LIBS(dlgetmodinfo, [dl xpdl])