[packages/zlib] add workaround for regression in java's jar util; rel 2
atler
atler at pld-linux.org
Wed Mar 30 16:06:48 CEST 2022
commit a761d832428b69704ef3d1be98627a62c5c856f8
Author: Jan Palus <atler at pld-linux.org>
Date: Wed Mar 30 16:05:09 2022 +0200
add workaround for regression in java's jar util; rel 2
see https://github.com/madler/zlib/issues/613
java-regr-workaround.patch | 25 +++++++++++++++++++++++++
zlib.spec | 4 +++-
2 files changed, 28 insertions(+), 1 deletion(-)
---
diff --git a/zlib.spec b/zlib.spec
index 352e781..fbbcc2b 100644
--- a/zlib.spec
+++ b/zlib.spec
@@ -18,13 +18,14 @@ Summary(tr.UTF-8): Sıkıştırma işlemleri için kitaplık
Summary(uk.UTF-8): Бібліотека для компресії та декомпресії
Name: zlib
Version: 1.2.12
-Release: 1
+Release: 2
License: BSD
Group: Libraries
Source0: http://www.zlib.net/current/%{name}-%{version}.tar.gz
# Source0-md5: 5fc414a9726be31427b440b434d05f78
Patch0: %{name}-asm.patch
Patch1: cc.patch
+Patch2: java-regr-workaround.patch
URL: http://www.zlib.net/
BuildRequires: autoconf >= 2.50
BuildRequires: automake
@@ -304,6 +305,7 @@ cp contrib/amd64/amd64-match.S match.S
%endif
%endif
%patch1 -p1
+%patch2 -p1
%build
CC="%{__cc}" \
diff --git a/java-regr-workaround.patch b/java-regr-workaround.patch
new file mode 100644
index 0000000..d308a75
--- /dev/null
+++ b/java-regr-workaround.patch
@@ -0,0 +1,25 @@
+diff --git a/crc32.c b/crc32.c
+index a1bdce5..748b7ba 100644
+--- a/crc32.c
++++ b/crc32.c
+@@ -19,6 +19,7 @@
+ MAKECRCH can be #defined to write out crc32.h. A main() routine is also
+ produced, so that this one source file can be compiled to an executable.
+ */
++#include <limits.h>
+
+ #ifdef MAKECRCH
+ # include <stdio.h>
+@@ -1065,7 +1066,12 @@ unsigned long ZEXPORT crc32(crc, buf, len)
+ const unsigned char FAR *buf;
+ uInt len;
+ {
++/* if sizeof(unsigned long) > 4 */
++#if ULONG_MAX > 0xffffffffUL
++ return crc32_z(crc & 0xffffffffUL, buf, len);
++#else
+ return crc32_z(crc, buf, len);
++#endif
+ }
+
+ /* ========================================================================= */
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/zlib.git/commitdiff/a761d832428b69704ef3d1be98627a62c5c856f8
More information about the pld-cvs-commit
mailing list