From 221199478908c233b3039851e169ab995a6bd2f0 Mon Sep 17 00:00:00 2001 From: Kalle Olavi Niemitalo Date: Mon, 11 Jun 2007 10:15:43 +0300 Subject: [PATCH] Check for gzclearerr in configure. Document needing zlib >= 1.2.0.2. It was reported at elinks-dev on 2007-06-03 that Solaris 10 comes with zlib 1.1.4, which does not include gzclearerr(), which ELinks nowadays requires. It would be possible to rewrite the decompression support to use deflate() directly and avoid stdio, in which case gzclearerr() would not be needed. That will take some time however, so I'm not attempting it for ELinks 0.12.0. Instead, I'm just disabling gzip decompression entirely if zlib is too old. --- NEWS | 1 + configure.in | 2 +- doc/installation.txt | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 7d75c260a..6b68e4a27 100644 --- a/NEWS +++ b/NEWS @@ -44,6 +44,7 @@ Incompatibilities: and its security goals are undocumented. If you must enable ECMAScript support, it would be prudent to restrict the ELinks process with a sandbox of some kind. +* Gzip decompression support now requires zlib 1.2.0.2 or later. * bugs 871, 752: The numbering of terminal.*.colors no longer depends on config options. This change makes elinks.conf portable between different configurations but unfortunately not between this and diff --git a/configure.in b/configure.in index 8a9adf54b..4edcd60b3 100644 --- a/configure.in +++ b/configure.in @@ -477,7 +477,7 @@ AC_DEFUN([EL_CONFIG_OPTIONAL_LIBRARY], EL_CONFIG_OPTIONAL_LIBRARY(CONFIG_GPM, gpm, gpm.h, gpm, Gpm_Open, [ --without-gpm disable gpm (mouse) support]) -EL_CONFIG_OPTIONAL_LIBRARY(CONFIG_GZIP, zlib, zlib.h, z, gzdopen, +EL_CONFIG_OPTIONAL_LIBRARY(CONFIG_GZIP, zlib, zlib.h, z, gzclearerr, [ --without-zlib disable zlib support]) EL_CONFIG_OPTIONAL_LIBRARY(CONFIG_BZIP2, bzlib, bzlib.h, bz2, BZ2_bzReadOpen, diff --git a/doc/installation.txt b/doc/installation.txt index efabb1447..95c7da037 100644 --- a/doc/installation.txt +++ b/doc/installation.txt @@ -41,7 +41,7 @@ ifndef::installation-webpage[] See <> \ endif::installation-webpage[] for more info. -GNU zip For handling compressed documents both locally and \ +zlib 1.2.0.2 or later For handling compressed documents both locally and \ sent from server. bzip2 For handling local compressed documents. OpenSSL or GNU TLS For handling secure HTTP browsing.