diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2015-03-29 07:12:38 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2015-03-29 07:13:00 -0700 |
commit | 243340ad57e30de3c15cffe6e4af0381995f15d9 (patch) | |
tree | d8d22601296073d341535ae9b32336c069553b6e /bfd/configure.ac | |
parent | ea6b7543b422836409fe7848abbfcb452ad26398 (diff) | |
download | gdb-243340ad57e30de3c15cffe6e4af0381995f15d9.zip gdb-243340ad57e30de3c15cffe6e4af0381995f15d9.tar.gz gdb-243340ad57e30de3c15cffe6e4af0381995f15d9.tar.bz2 |
Add --with-system-zlib in bfd
This patch adds --with-system-zlib and remove --with-zlib in bfd.
* Makefile.am (ZLIB): New.
(ZLIBINC): Likewise.
(AM_CFLAGS): Add $(ZLIBINC).
(libbfd_la_LIBADD): Add $(ZLIB).
* compress.c: Don't check HAVE_ZLIB_H to include <zlib.h>.
(decompress_contents): Don't check HAVE_ZLIB_H.
(decompress_contents): Likewise.
(bfd_compress_section_contents): Likewise.
(bfd_get_full_section_contents): Likewise.
(bfd_init_section_decompress_status): Likewise.
(bfd_init_section_compress_status): Likewise.
* configure.ac (AM_ZLIB): Removed
(zlibdir): New. AC_SUBST.
(zlibinc): Likewise.
Add --with-system-zlib.
* Makefile.in: Regenerated.
* acinclude.m4: Likewise.
* config.in: Likewise.
* configure: Likewise.
* doc/Makefile.in: Likewise.
Diffstat (limited to 'bfd/configure.ac')
-rw-r--r-- | bfd/configure.ac | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/bfd/configure.ac b/bfd/configure.ac index a1b2035..5426781 100644 --- a/bfd/configure.ac +++ b/bfd/configure.ac @@ -236,9 +236,16 @@ AC_CHECK_DECLS(snprintf) AC_CHECK_DECLS(vsnprintf) AC_CHECK_DECLS(strnlen) -# Link in zlib if we can. This allows us to read compressed debug sections. -# This is used only by compress.c. -AM_ZLIB +# Use the system's zlib library. +zlibdir=-L../zlib +zlibinc="-I\$(srcdir)/../zlib" +AC_ARG_WITH(system-zlib, +[AS_HELP_STRING([--with-system-zlib], [use installed libz])], +zlibdir= +zlibinc= +) +AC_SUBST(zlibdir) +AC_SUBST(zlibinc) # If we are configured native, pick a core file support file. COREFILE= |