diff options
| author | Paul Eggert <eggert@cs.ucla.edu> | 2013-08-12 09:05:58 -0700 |
|---|---|---|
| committer | Paul Eggert <eggert@cs.ucla.edu> | 2013-08-12 09:05:58 -0700 |
| commit | 1d238bc75ac833eb28a72f24cc1acd79ec5999d7 (patch) | |
| tree | 65fb7ea2c7cdb66d40fbbce440e4623975c9568f | |
| parent | 01f1a9ab4f3eedbbf99140195c2530b7c242de4f (diff) | |
| download | emacs-1d238bc75ac833eb28a72f24cc1acd79ec5999d7.tar.gz | |
Minor zlib configuration tweaks.
* configure.ac (HAVE_ZLIB): Don't assume zlib is linked if PNG is.
* src/decompress.c (fn_inflateInit2) [!WINDOWSNT]:
Don't assume presence of fn_inflateInit2_ zlib internal function.
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | configure.ac | 21 | ||||
| -rw-r--r-- | src/ChangeLog | 6 | ||||
| -rw-r--r-- | src/decompress.c | 8 |
4 files changed, 21 insertions, 19 deletions
diff --git a/ChangeLog b/ChangeLog index 641cbefce20..f579c5226f1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2013-08-12 Paul Eggert <eggert@cs.ucla.edu> + + Minor zlib configuration tweaks. + * configure.ac (HAVE_ZLIB): Don't assume zlib is linked if PNG is. + 2013-08-12 Eli Zaretskii <eliz@gnu.org> * configure.ac (LIBZ): Comment on w32 peculiarities regarding LIBZ. diff --git a/configure.ac b/configure.ac index 5daf84be2ba..b6c7dacd997 100644 --- a/configure.ac +++ b/configure.ac @@ -2946,21 +2946,12 @@ AC_SUBST(LIBPNG) HAVE_ZLIB=no LIBZ= if test "${with_zlib}" != "no"; then - if test "${HAVE_PNG}" = "yes"; then - ### PNG depends on zlib, so if we have PNG, we have zlib. - ### Note: w32 does not link against libpng, but instead loads it - ### dynamically, but it also does the same with zlib. So it is OK - ### not to have -lz in LIBZ on w32. - HAVE_ZLIB=yes - else - ### No PNG, so check zlib ourselves. - OLIBS=$LIBS - AC_SEARCH_LIBS([inflateEnd], [z], [HAVE_ZLIB=yes]) - LIBS=$OLIBS - case $ac_cv_search_inflateEnd in - -*) LIBZ=$ac_cv_search_inflateEnd ;; - esac - fi + OLIBS=$LIBS + AC_SEARCH_LIBS([inflateEnd], [z], [HAVE_ZLIB=yes]) + LIBS=$OLIBS + case $ac_cv_search_inflateEnd in + -*) LIBZ=$ac_cv_search_inflateEnd ;; + esac fi if test "${HAVE_ZLIB}" = "yes"; then AC_DEFINE([HAVE_ZLIB], 1, [Define to 1 if you have the zlib library (-lz).]) diff --git a/src/ChangeLog b/src/ChangeLog index 3a8fcfe7e9c..cf851d5bec0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2013-08-12 Paul Eggert <eggert@cs.ucla.edu> + + Minor zlib configuration tweaks. + * decompress.c (fn_inflateInit2) [!WINDOWSNT]: + Don't assume presence of fn_inflateInit2_ zlib internal function. + 2013-08-12 Lars Magne Ingebrigtsen <larsi@gnus.org> * decompress.c (Fzlib_decompress_gzipped_region): Rename to diff --git a/src/decompress.c b/src/decompress.c index 3605d446e5a..4e4e3a9c7dc 100644 --- a/src/decompress.c +++ b/src/decompress.c @@ -67,17 +67,17 @@ init_zlib_functions (void) return 1; } +#define fn_inflateInit2(strm, windowBits) \ + fn_inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) + #else /* !WINDOWSNT */ -#define fn_inflateInit2_ inflateInit2_ +#define fn_inflateInit2 inflateInit2 #define fn_inflate inflate #define fn_inflateEnd inflateEnd #endif /* WINDOWSNT */ -#define fn_inflateInit2(strm, windowBits) \ - fn_inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) - struct decompress_unwind_data { |
