Hello community,

here is the log from the commit of package zlib for openSUSE:Leap:15.2 checked 
in at 2020-05-29 18:49:08
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Leap:15.2/zlib (Old)
 and      /work/SRC/openSUSE:Leap:15.2/.zlib.new.3606 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "zlib"

Fri May 29 18:49:08 2020 rev:15 rq:809031 version:1.2.11

Changes:
--------
--- /work/SRC/openSUSE:Leap:15.2/zlib/zlib.changes      2020-01-15 
16:32:51.628894122 +0100
+++ /work/SRC/openSUSE:Leap:15.2/.zlib.new.3606/zlib.changes    2020-05-29 
18:49:10.332201822 +0200
@@ -1,0 +2,20 @@
+Thu Apr 23 08:17:19 UTC 2020 - Tomáš Chvátal <tchva...@suse.com>
+
+- Update 410.patch to contain latest fixes from IBM bsc#1166260
+  * The build behaviour changed
+
+-------------------------------------------------------------------
+Tue Oct 29 10:47:18 UTC 2019 - Tomáš Chvátal <tchva...@suse.com>
+
+- Update the zlib-no-version-check.patch to be even more forgiving
+  with the versions on the zlib to allow updates without rebuilds
+
+-------------------------------------------------------------------
+Mon Oct 21 07:11:58 UTC 2019 - Tomáš Chvátal <tchva...@suse.com>
+
+- Add SUSE specific patch to fix bsc#1138793, we simply don't want
+  to test if the app was linked with exactly same version of zlib
+  like the one that is present on the runtime:
+  * zlib-no-version-check.patch
+
+-------------------------------------------------------------------

New:
----
  zlib-no-version-check.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ zlib.spec ++++++
--- /var/tmp/diff_new_pack.QcQ53c/_old  2020-05-29 18:49:10.796203153 +0200
+++ /var/tmp/diff_new_pack.QcQ53c/_new  2020-05-29 18:49:10.800203164 +0200
@@ -21,7 +21,6 @@
 Release:        0
 Summary:        Library implementing the DEFLATE compression algorithm
 License:        Zlib
-Group:          Development/Libraries/C and C++
 URL:            http://www.zlib.net/
 Source0:        http://zlib.net/zlib-%{version}.tar.gz
 Source1:        http://zlib.net/zlib-%{version}.tar.gz.asc
@@ -39,6 +38,9 @@
 Patch3:         zlib-power8-fate325307.patch
 #PATCH-FIX-UPSTREAM https://github.com/madler/zlib/pull/410
 Patch4:         410.patch
+#PATCH-FIX-SUSE do not check exact version match as the lib can be updated
+#               we should simply rely on soname versioning to protect us
+Patch5:         zlib-no-version-check.patch
 BuildRequires:  autoconf
 BuildRequires:  automake
 BuildRequires:  libtool
@@ -52,7 +54,6 @@
 
 %package -n libz1
 Summary:        Library implementing the DEFLATE compression algorithm
-Group:          System/Libraries
 Provides:       %{name} = %{version}-%{release}
 Obsoletes:      %{name} < %{version}-%{release}
 
@@ -64,7 +65,6 @@
 
 %package devel
 Summary:        Development files for zlib, a data compression library
-Group:          Development/Languages/C and C++
 Requires:       glibc-devel
 Requires:       libz1 = %{version}
 
@@ -86,7 +86,6 @@
 
 %package devel-static
 Summary:        Static library for zlib
-Group:          Development/Languages/C and C++
 Requires:       %{name}-devel = %{version}
 Provides:       %{name}-devel:%{_libdir}/libz.a
 
@@ -101,14 +100,12 @@
 
 %package -n libminizip1
 Summary:        Library for manipulation with .zip archives
-Group:          System/Libraries
 
 %description -n libminizip1
 Minizip is a library for manipulation with files from .zip archives.
 
 %package -n minizip-devel
 Summary:        Development files for the minizip library
-Group:          Development/Languages/C and C++
 Requires:       %{name}-devel = %{version}
 Requires:       libminizip1 = %{version}
 Requires:       pkgconfig
@@ -124,31 +121,30 @@
 %patch2 -p1
 %patch3 -p1
 %patch4 -p1
+%patch5 -p1
 cp %{SOURCE4} .
 
 %build
 %global _lto_cflags %{_lto_cflags} -ffat-lto-objects
 export LDFLAGS="-Wl,-z,relro,-z,now"
-%ifarch s390x s390
-export CFLAGS="%{optflags} -DDFLTCC"
-%define addopts OBJA=dfltcc.o PIC_OBJA=dfltcc.lo
-%else
 export CFLAGS="%{optflags}"
-%define addopts %{nil}
-%endif
 # For sure not autotools build
 CC="cc" ./configure \
     --shared \
     --prefix=%{_prefix} \
-    --libdir=/%{_lib}
+    --libdir=/%{_lib} \
+%ifarch s390x s390
+    --dfltcc \
+%endif
+    %{nil}
 
 %if %{do_profiling}
-  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}" 
%{addopts}
+  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}"
   make check %{?_smp_mflags}
   make %{?_smp_mflags} clean
-  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_feedback}" 
%{addopts}
+  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_feedback}"
 %else
-  make %{?_smp_mflags} %{addopts}
+  make %{?_smp_mflags}
 %endif
 
 # And build minizip
@@ -157,7 +153,7 @@
 %configure \
     --disable-static \
     --disable-silent-rules
-make %{?_smp_mflags} %{addopts}
+make %{?_smp_mflags}
 
 %check
 make check %{?_smp_mflags}

++++++ 410.patch ++++++
--- /var/tmp/diff_new_pack.QcQ53c/_old  2020-05-29 18:49:10.824203234 +0200
+++ /var/tmp/diff_new_pack.QcQ53c/_new  2020-05-29 18:49:10.828203245 +0200
@@ -1,9 +1,9 @@
-From 230b5152e9660eb5e5821c2dbc84ae300dfe1fb1 Mon Sep 17 00:00:00 2001
+From 79ccd96ec69d2367291568c586aeaae941d2635c Mon Sep 17 00:00:00 2001
 From: Ilya Leoshkevich <i...@linux.ibm.com>
 Date: Wed, 18 Jul 2018 13:14:07 +0200
 Subject: [PATCH] Add support for IBM Z hardware-accelerated deflate
 
-Future versions of IBM Z mainframes will provide DFLTCC instruction,
+IBM Z mainframes starting from version z15 provide DFLTCC instruction,
 which implements deflate algorithm in hardware with estimated
 compression and decompression performance orders of magnitude faster
 than the current zlib and ratio comparable with that of level 1.
@@ -11,15 +11,15 @@
 This patch adds DFLTCC support to zlib. In order to enable it, the
 following build commands should be used:
 
-    $ CFLAGS=-DDFLTCC ./configure
-    $ make OBJA=dfltcc.o PIC_OBJA=dfltcc.lo
+    $ ./configure --dfltcc
+    $ make
 
 When built like this, zlib would compress in hardware on level 1, and in
 software on all other levels. Decompression will always happen in
 hardware. In order to enable DFLTCC compression for levels 1-6 (i.e. to
 make it used by default) one could either add -DDFLTCC_LEVEL_MASK=0x7e
-at compile time, or set the environment variable DFLTCC_LEVEL_MASK to
-0x7e at run time.
+to CFLAGS at compile time, or set the environment variable
+DFLTCC_LEVEL_MASK to 0x7e at run time.
 
 Two DFLTCC compression calls produce the same results only when they
 both are made on machines of the same generation, and when the
@@ -34,15 +34,14 @@
     * inflate(Z_BLOCK) and inflate(Z_TREES)
     * inflateMark()
     * inflatePrime()
-    * deflateParams() after the first deflate() call
 
 When used, these functions will either switch to software, or, in case
 this is not possible, gracefully fail.
 
-This patch tries to add DFLTCC support in a least intrusive way.
-All SystemZ-specific code was placed into a separate file, but
+This patch tries to add DFLTCC support in the least intrusive way.
+All SystemZ-specific code is placed into a separate file, but
 unfortunately there is still a noticeable amount of changes in the
-main zlib code. Below is the summary of those changes.
+main zlib code. Below is the summary of these changes.
 
 DFLTCC takes as arguments a parameter block, an input buffer, an output
 buffer and a window. Since DFLTCC requires parameter block to be
@@ -61,9 +60,12 @@
 parameter block, which is allocated alongside zlib state, using
 the new DEFLATE_RESET_KEEP_HOOK and INFLATE_RESET_KEEP_HOOK macros.
 
-In order to make unsupported deflateParams(), inflatePrime() and
-inflateMark() calls to fail gracefully, the new DEFLATE_PARAMS_HOOK,
-INFLATE_PRIME_HOOK and INFLATE_MARK_HOOK macros were introduced.
+The new DEFLATE_PARAMS_HOOK switches between hardware and software
+deflate implementations when deflateParams() arguments demand this.
+
+In order to make unsupported inflatePrime() and inflateMark() calls
+fail gracefully, the new INFLATE_PRIME_HOOK and INFLATE_MARK_HOOK macros
+were introduced.
 
 The algorithm implemented in hardware has different compression ratio
 than the one implemented in software. In order for deflateBound() to
@@ -93,12 +95,12 @@
 updatewindow and made ZLIB_INTERNAL.
 ---
  Makefile.in                   |   8 +
- configure                     |  13 +
+ configure                     |  20 +
  contrib/README.contrib        |   4 +
- contrib/s390/dfltcc.c         | 904 ++++++++++++++++++++++++++++++++++
- contrib/s390/dfltcc.h         |  55 +++
- contrib/s390/dfltcc_deflate.h |  50 ++
- deflate.c                     |  60 ++-
+ contrib/s390/dfltcc.c         | 920 ++++++++++++++++++++++++++++++++++
+ contrib/s390/dfltcc.h         |  55 ++
+ contrib/s390/dfltcc_deflate.h |  54 ++
+ deflate.c                     |  68 ++-
  deflate.h                     |  12 +
  gzguts.h                      |   4 +
  inflate.c                     |  85 +++-
@@ -106,7 +108,7 @@
  test/infcover.c               |   2 +-
  test/minigzip.c               |   4 +
  trees.c                       |  13 +-
- 14 files changed, 1165 insertions(+), 51 deletions(-)
+ 14 files changed, 1197 insertions(+), 54 deletions(-)
  create mode 100644 contrib/s390/dfltcc.c
  create mode 100644 contrib/s390/dfltcc.h
  create mode 100644 contrib/s390/dfltcc_deflate.h
@@ -134,7 +136,28 @@
 ===================================================================
 --- zlib-1.2.11.orig/configure
 +++ zlib-1.2.11/configure
-@@ -911,6 +911,19 @@ EOF
+@@ -114,6 +114,7 @@ case "$1" in
+       echo '  configure [--const] [--zprefix] [--prefix=PREFIX]  
[--eprefix=EXPREFIX]' | tee -a configure.log
+       echo '    [--static] [--64] [--libdir=LIBDIR] [--sharedlibdir=LIBDIR]' 
| tee -a configure.log
+       echo '    [--includedir=INCLUDEDIR] [--archs="-arch i386 -arch 
x86_64"]' | tee -a configure.log
++      echo '    [--dfltcc]' | tee -a configure.log
+         exit 0 ;;
+     -p*=* | --prefix=*) prefix=`echo $1 | sed 's/.*=//'`; shift ;;
+     -e*=* | --eprefix=*) exec_prefix=`echo $1 | sed 's/.*=//'`; shift ;;
+@@ -137,6 +138,12 @@ case "$1" in
+     -c* | --const) zconst=1; shift ;;
+     -w* | --warn) warn=1; shift ;;
+     -d* | --debug) debug=1; shift ;;
++    --dfltcc)
++      CFLAGS="$CFLAGS -DDFLTCC"
++      OBJC="$OBJC dfltcc.o"
++      PIC_OBJC="$PIC_OBJC dfltcc.lo"
++      shift
++      ;;
+     *)
+       echo "unknown option: $1" | tee -a configure.log
+       echo "$0 --help for help" | tee -a configure.log
+@@ -911,6 +918,19 @@ EOF
    fi
  fi
  
@@ -173,14 +196,14 @@
 ===================================================================
 --- /dev/null
 +++ zlib-1.2.11/contrib/s390/dfltcc.c
-@@ -0,0 +1,904 @@
+@@ -0,0 +1,920 @@
 +/* dfltcc.c - SystemZ DEFLATE CONVERSION CALL support. */
 +
 +/*
 +   Use the following commands to build zlib with DFLTCC support:
 +
-+        $ CFLAGS=-DDFLTCC ./configure
-+        $ make OBJA=dfltcc.o PIC_OBJA=dfltcc.lo
++        $ ./configure --dfltcc
++        $ make
 +*/
 +
 +#define _GNU_SOURCE
@@ -407,31 +430,28 @@
 +/*
 +   Compress.
 + */
-+local inline int dfltcc_are_params_ok(int level,
-+                                      uInt window_bits,
-+                                      int strategy,
-+                                      uLong level_mask);
-+local inline int dfltcc_are_params_ok(level, window_bits, strategy, 
level_mask)
++local inline int dfltcc_can_deflate_with_params(z_streamp strm,
++                                                int level,
++                                                uInt window_bits,
++                                                int strategy);
++local inline int dfltcc_can_deflate_with_params(strm,
++                                                level,
++                                                window_bits,
++                                                strategy)
++    z_streamp strm;
 +    int level;
 +    uInt window_bits;
 +    int strategy;
-+    uLong level_mask;
-+{
-+    return (level_mask & (1 << level)) != 0 &&
-+        (window_bits == HB_BITS) &&
-+        (strategy == Z_FIXED || strategy == Z_DEFAULT_STRATEGY);
-+}
-+
-+
-+int ZLIB_INTERNAL dfltcc_can_deflate(strm)
-+    z_streamp strm;
 +{
 +    deflate_state FAR *state = (deflate_state FAR *)strm->state;
 +    struct dfltcc_state FAR *dfltcc_state = GET_DFLTCC_STATE(state);
 +
 +    /* Unsupported compression settings */
-+    if (!dfltcc_are_params_ok(state->level, state->w_bits, state->strategy,
-+                              dfltcc_state->level_mask))
++    if ((dfltcc_state->level_mask & (1 << level)) == 0)
++        return 0;
++    if (window_bits != HB_BITS)
++        return 0;
++    if (strategy != Z_FIXED && strategy != Z_DEFAULT_STRATEGY)
 +        return 0;
 +
 +    /* Unsupported hardware */
@@ -443,6 +463,17 @@
 +    return 1;
 +}
 +
++int ZLIB_INTERNAL dfltcc_can_deflate(strm)
++    z_streamp strm;
++{
++    deflate_state FAR *state = (deflate_state FAR *)strm->state;
++
++    return dfltcc_can_deflate_with_params(strm,
++                                          state->level,
++                                          state->w_bits,
++                                          state->strategy);
++}
++
 +local void dfltcc_gdht OF((z_streamp strm));
 +local void dfltcc_gdht(strm)
 +    z_streamp strm;
@@ -526,22 +557,24 @@
 +    soft_bcc = 0;
 +    no_flush = flush == Z_NO_FLUSH;
 +
-+    /* Trailing empty block. Switch to software, except when Continuation Flag
-+     * is set, which means that DFLTCC has buffered some output in the
-+     * parameter block and needs to be called again in order to flush it.
++    /* No input data. Return, except when Continuation Flag is set, which 
means
++     * that DFLTCC has buffered some output in the parameter block and needs 
to
++     * be called again in order to flush it.
 +     */
-+    if (flush == Z_FINISH && strm->avail_in == 0 && !param->cf) {
-+        if (param->bcf) {
-+            /* A block is still open, and the hardware does not support 
closing
-+             * blocks without adding data. Thus, close it manually.
-+             */
++    if (strm->avail_in == 0 && !param->cf) {
++        /* A block is still open, and the hardware does not support closing
++         * blocks without adding data. Thus, close it manually.
++         */
++        if (!no_flush && param->bcf) {
 +            send_eobs(strm, param);
 +            param->bcf = 0;
 +        }
-+        return 0;
-+    }
-+
-+    if (strm->avail_in == 0 && !param->cf) {
++        /* Let one of deflate_* functions write a trailing empty block. */
++        if (flush == Z_FINISH)
++            return 0;
++        /* Clear history. */
++        if (flush == Z_FULL_FLUSH)
++            param->hl = 0;
 +        *result = need_more;
 +        return 1;
 +    }
@@ -595,7 +628,7 @@
 +    param->cvt = state->wrap == 2 ? CVT_CRC32 : CVT_ADLER32;
 +    if (!no_flush)
 +        /* We need to close a block. Always do this in software - when there 
is
-+         * no input data, the hardware will not nohor BCC. */
++         * no input data, the hardware will not honor BCC. */
 +        soft_bcc = 1;
 +    if (flush == Z_FINISH && !param->bcf)
 +        /* We are about to open a BFINAL block, set Block Header Final bit
@@ -610,8 +643,8 @@
 +    param->sbb = (unsigned int)state->bi_valid;
 +    if (param->sbb > 0)
 +        *strm->next_out = (Bytef)state->bi_buf;
-+    if (param->hl)
-+        param->nt = 0; /* Honor history */
++    /* Honor history and check value */
++    param->nt = 0;
 +    param->cv = state->wrap == 2 ? ZSWAP32(strm->adler) : strm->adler;
 +
 +    /* When opening a block, choose a Huffman-Table Type */
@@ -971,17 +1004,20 @@
 +   fly with deflateParams, we need to convert between hardware and software
 +   window formats.
 +*/
-+int ZLIB_INTERNAL dfltcc_deflate_params(strm, level, strategy)
++int ZLIB_INTERNAL dfltcc_deflate_params(strm, level, strategy, flush)
 +    z_streamp strm;
 +    int level;
 +    int strategy;
++    int *flush;
 +{
 +    deflate_state FAR *state = (deflate_state FAR *)strm->state;
 +    struct dfltcc_state FAR *dfltcc_state = GET_DFLTCC_STATE(state);
 +    struct dfltcc_param_v0 FAR *param = &dfltcc_state->param;
 +    int could_deflate = dfltcc_can_deflate(strm);
-+    int can_deflate = dfltcc_are_params_ok(level, state->w_bits, strategy,
-+                                           dfltcc_state->level_mask);
++    int can_deflate = dfltcc_can_deflate_with_params(strm,
++                                                     level,
++                                                     state->w_bits,
++                                                     strategy);
 +
 +    if (can_deflate == could_deflate)
 +        /* We continue to work in the same mode - no changes needed */
@@ -991,8 +1027,11 @@
 +        /* DFLTCC was not used yet - no changes needed */
 +        return Z_OK;
 +
-+    /* Switching between hardware and software is not implemented */
-+    return Z_STREAM_ERROR;
++    /* For now, do not convert between window formats - simply get rid of the
++     * old data instead.
++     */
++    *flush = Z_FULL_FLUSH;
++    return Z_OK;
 +}
 +
 +/*
@@ -1142,7 +1181,7 @@
 ===================================================================
 --- /dev/null
 +++ zlib-1.2.11/contrib/s390/dfltcc_deflate.h
-@@ -0,0 +1,50 @@
+@@ -0,0 +1,54 @@
 +#ifndef DFLTCC_DEFLATE_H
 +#define DFLTCC_DEFLATE_H
 +
@@ -1154,7 +1193,8 @@
 +                                     block_state *result));
 +int ZLIB_INTERNAL dfltcc_deflate_params OF((z_streamp strm,
 +                                            int level,
-+                                            int strategy));
++                                            int strategy,
++                                            int *flush));
 +int ZLIB_INTERNAL dfltcc_deflate_set_dictionary OF((z_streamp strm,
 +                                                    const Bytef *dictionary,
 +                                                    uInt dict_length));
@@ -1174,11 +1214,14 @@
 +    } while (0)
 +#define DEFLATE_RESET_KEEP_HOOK(strm) \
 +    dfltcc_reset((strm), sizeof(deflate_state))
-+#define DEFLATE_PARAMS_HOOK(strm, level, strategy) \
++#define DEFLATE_PARAMS_HOOK(strm, level, strategy, hook_flush) \
 +    do { \
 +        int err; \
 +\
-+        err = dfltcc_deflate_params((strm), (level), (strategy)); \
++        err = dfltcc_deflate_params((strm), \
++                                    (level), \
++                                    (strategy), \
++                                    (hook_flush)); \
 +        if (err == Z_STREAM_ERROR) \
 +            return err; \
 +    } while (0)
@@ -1221,7 +1264,7 @@
 +#define DEFLATE_SET_DICTIONARY_HOOK(strm, dict, dict_len) do {} while (0)
 +#define DEFLATE_GET_DICTIONARY_HOOK(strm, dict, dict_len) do {} while (0)
 +#define DEFLATE_RESET_KEEP_HOOK(strm) do {} while (0)
-+#define DEFLATE_PARAMS_HOOK(strm, level, strategy) do {} while (0)
++#define DEFLATE_PARAMS_HOOK(strm, level, strategy, hook_flush) do {} while (0)
 +#define DEFLATE_BOUND_ADJUST_COMPLEN(strm, complen, sourceLen) do {} while (0)
 +#define DEFLATE_NEED_CONSERVATIVE_BOUND(strm) 0
 +#define DEFLATE_HOOK(strm, flush, bstate) 0
@@ -1285,15 +1328,33 @@
      return Z_OK;
  }
  
-@@ -584,6 +601,7 @@ int ZEXPORT deflateParams(strm, level, s
+@@ -572,6 +589,7 @@ int ZEXPORT deflateParams(strm, level, s
+ {
+     deflate_state *s;
+     compress_func func;
++    int hook_flush = Z_NO_FLUSH;
+ 
+     if (deflateStateCheck(strm)) return Z_STREAM_ERROR;
+     s = strm->state;
+@@ -584,12 +602,14 @@ int ZEXPORT deflateParams(strm, level, s
      if (level < 0 || level > 9 || strategy < 0 || strategy > Z_FIXED) {
          return Z_STREAM_ERROR;
      }
-+    DEFLATE_PARAMS_HOOK(strm, level, strategy);
++    DEFLATE_PARAMS_HOOK(strm, level, strategy, &hook_flush);
      func = configuration_table[s->level].func;
  
-     if ((strategy != s->strategy || func != configuration_table[level].func) 
&&
-@@ -659,6 +677,7 @@ uLong ZEXPORT deflateBound(strm, sourceL
+-    if ((strategy != s->strategy || func != configuration_table[level].func) 
&&
+-        s->high_water) {
++    if ((strategy != s->strategy || func != configuration_table[level].func ||
++         hook_flush != Z_NO_FLUSH) && s->high_water) {
+         /* Flush the last buffer: */
+-        int err = deflate(strm, Z_BLOCK);
++        int err = deflate(strm, RANK(hook_flush) > RANK(Z_BLOCK) ?
++                          hook_flush : Z_BLOCK);
+         if (err == Z_STREAM_ERROR)
+             return err;
+         if (strm->avail_out == 0)
+@@ -659,6 +679,7 @@ uLong ZEXPORT deflateBound(strm, sourceL
      /* conservative upper bound for compressed data */
      complen = sourceLen +
                ((sourceLen + 7) >> 3) + ((sourceLen + 63) >> 6) + 5;
@@ -1301,7 +1362,7 @@
  
      /* if can't get parameters, return conservative bound plus zlib wrapper */
      if (deflateStateCheck(strm))
-@@ -700,7 +719,8 @@ uLong ZEXPORT deflateBound(strm, sourceL
+@@ -700,7 +721,8 @@ uLong ZEXPORT deflateBound(strm, sourceL
      }
  
      /* if not default parameters, return conservative bound */
@@ -1311,7 +1372,7 @@
          return complen + wraplen;
  
      /* default settings: return tight bound for that case */
-@@ -727,7 +747,7 @@ local void putShortMSB (s, b)
+@@ -727,7 +749,7 @@ local void putShortMSB (s, b)
   * applications may wish to modify it to avoid allocating a large
   * strm->next_out buffer and copying into it. (See also read_buf()).
   */
@@ -1320,7 +1381,7 @@
      z_streamp strm;
  {
      unsigned len;
-@@ -997,7 +1017,8 @@ int ZEXPORT deflate (strm, flush)
+@@ -997,7 +1019,8 @@ int ZEXPORT deflate (strm, flush)
          (flush != Z_NO_FLUSH && s->status != FINISH_STATE)) {
          block_state bstate;
  
@@ -1330,7 +1391,7 @@
                   s->strategy == Z_HUFFMAN_ONLY ? deflate_huff(s, flush) :
                   s->strategy == Z_RLE ? deflate_rle(s, flush) :
                   (*(configuration_table[s->level].func))(s, flush);
-@@ -1086,9 +1107,9 @@ int ZEXPORT deflateEnd (strm)
+@@ -1086,9 +1109,9 @@ int ZEXPORT deflateEnd (strm)
      TRY_FREE(strm, strm->state->pending_buf);
      TRY_FREE(strm, strm->state->head);
      TRY_FREE(strm, strm->state->prev);
@@ -1342,7 +1403,7 @@
      strm->state = Z_NULL;
  
      return status == BUSY_STATE ? Z_DATA_ERROR : Z_OK;
-@@ -1119,13 +1140,13 @@ int ZEXPORT deflateCopy (dest, source)
+@@ -1119,13 +1142,13 @@ int ZEXPORT deflateCopy (dest, source)
  
      zmemcpy((voidpf)dest, (voidpf)source, sizeof(z_stream));
  
@@ -1359,7 +1420,7 @@
      ds->prev   = (Posf *)  ZALLOC(dest, ds->w_size, sizeof(Pos));
      ds->head   = (Posf *)  ZALLOC(dest, ds->hash_size, sizeof(Pos));
      overlay = (ushf *) ZALLOC(dest, ds->lit_bufsize, sizeof(ush)+2);
-@@ -1174,7 +1195,8 @@ local unsigned read_buf(strm, buf, size)
+@@ -1174,7 +1197,8 @@ local unsigned read_buf(strm, buf, size)
      strm->avail_in  -= len;
  
      zmemcpy(buf, strm->next_in, len);


++++++ zlib-no-version-check.patch ++++++
Index: zlib-1.2.11/infback.c
===================================================================
--- zlib-1.2.11.orig/infback.c
+++ zlib-1.2.11/infback.c
@@ -34,9 +34,6 @@ int stream_size;
 {
     struct inflate_state FAR *state;
 
-    if (version == Z_NULL || version[0] != ZLIB_VERSION[0] ||
-        stream_size != (int)(sizeof(z_stream)))
-        return Z_VERSION_ERROR;
     if (strm == Z_NULL || window == Z_NULL ||
         windowBits < 8 || windowBits > 15)
         return Z_STREAM_ERROR;
Index: zlib-1.2.11/inflate.c
===================================================================
--- zlib-1.2.11.orig/inflate.c
+++ zlib-1.2.11/inflate.c
@@ -219,9 +219,6 @@ int stream_size;
     int ret;
     struct inflate_state FAR *state;
 
-    if (version == Z_NULL || version[0] != ZLIB_VERSION[0] ||
-        stream_size != (int)(sizeof(z_stream)))
-        return Z_VERSION_ERROR;
     if (strm == Z_NULL) return Z_STREAM_ERROR;
     strm->msg = Z_NULL;                 /* in case we return an error */
     if (strm->zalloc == (alloc_func)0) {
Index: zlib-1.2.11/deflate.c
===================================================================
--- zlib-1.2.11.orig/deflate.c
+++ zlib-1.2.11/deflate.c
@@ -263,17 +263,12 @@ int ZEXPORT deflateInit2_(strm, level, m
 {
     deflate_state *s;
     int wrap = 1;
-    static const char my_version[] = ZLIB_VERSION;
 
     ushf *overlay;
     /* We overlay pending_buf and d_buf+l_buf. This works since the average
      * output size for (length,distance) codes is <= 24 bits.
      */
 
-    if (version == Z_NULL || version[0] != my_version[0] ||
-        stream_size != sizeof(z_stream)) {
-        return Z_VERSION_ERROR;
-    }
     if (strm == Z_NULL) return Z_STREAM_ERROR;
 
     strm->msg = Z_NULL;


Reply via email to