* acinclude.m4: Include ../config/zlib.m4.
authorJoel Brobecker <brobecker@gnat.com>
Tue, 24 Nov 2009 22:59:53 +0000 (22:59 +0000)
committerJoel Brobecker <brobecker@gnat.com>
Tue, 24 Nov 2009 22:59:53 +0000 (22:59 +0000)
        * configure.ac: Use AM_ZLIB to check for zlib support.
        * configure: Regenerate.

gdb/ChangeLog
gdb/acinclude.m4
gdb/configure
gdb/configure.ac

index a1056d7d61b59081086c336985ab24fb4c4a7926..e69bac29e3080ac6501c7cafcccba0520bf03d52 100644 (file)
@@ -1,3 +1,9 @@
+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
index c32e1ea4d3bb074dd392c003b42f9c2272b7bb4f..af4639b3250e79f38cb10fa10ada82229f40c03f 100644 (file)
@@ -32,6 +32,8 @@ sinclude([../config/lcmessage.m4])
 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
index 25ea875058acd2b514c7cb29658041d7fa4e4c50..b4492e7e6cb43c8229d493f325d34bc2eb7295cb 100755 (executable)
@@ -896,6 +896,7 @@ with_curses
 enable_profiling
 with_pkgversion
 with_bugurl
+with_zlib
 with_libiconv_prefix
 with_system_readline
 with_expat
@@ -1590,6 +1591,7 @@ Optional Packages:
                           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
@@ -8129,7 +8131,19 @@ fi
 
 
 # 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
@@ -8196,6 +8210,11 @@ done
 
 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
index 447663712edc5112069c4afecd5ff490adeb0887..8a738375a9b50cbac1ee4b9d47fcad4c82b90575 100644 (file)
@@ -423,7 +423,7 @@ AC_SEARCH_LIBS(gethostbyname, nsl)
 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])
This page took 0.040052 seconds and 4 git commands to generate.