diff --git a/backport-Fix-type-of-buffer-to-match-zip_random-signature.patch b/backport-Fix-type-of-buffer-to-match-zip_random-signature.patch new file mode 100644 index 0000000..547bdde --- /dev/null +++ b/backport-Fix-type-of-buffer-to-match-zip_random-signature.patch @@ -0,0 +1,27 @@ +From 49b35508503812dbac5286d3f6dda53cdb7b7b59 Mon Sep 17 00:00:00 2001 +From: Thomas Klausner +Date: Sun, 15 Apr 2018 21:09:22 +0200 +Subject: [PATCH] Fix type of buffer to match zip_random signature. + +Should fix a signedness warning on macOS, addressing +https://github.com/nih-at/libzip/pull/43/ +--- + regress/nonrandomopentest.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/regress/nonrandomopentest.c b/regress/nonrandomopentest.c +index 1da7497d..b20a4698 100644 +--- a/regress/nonrandomopentest.c ++++ b/regress/nonrandomopentest.c +@@ -38,7 +38,7 @@ + + int + main(int argc, const char *argv[]) { +- char buf[1024]; ++ zip_uint8_t buf[1024]; + int i; + + #ifdef HAVE_CRYPTO +-- +2.36.1 + diff --git a/libzip.spec b/libzip.spec index 4f860f3..8b3ef24 100644 --- a/libzip.spec +++ b/libzip.spec @@ -1,11 +1,13 @@ Name: libzip Version: 1.5.1 -Release: 4 +Release: 5 Summary: A C library for reading, creating, and modifying zip archives License: BSD URL: https://libzip.org/ Source0: https://libzip.org/download/libzip-%{version}.tar.xz +Patch6000: backport-Fix-type-of-buffer-to-match-zip_random-signature.patch + BuildRequires: gcc zlib-devel bzip2-devel openssl-devel cmake BuildRequires: perl-interpreter perl(Cwd) perl(File::Copy) perl(File::Path) perl(Getopt::Long) BuildRequires: perl(IPC::Open3) perl(Storable) perl(Symbol) perl(UNIVERSAL) perl(strict) perl(warnings) @@ -68,6 +70,9 @@ make test %{_mandir}/man3/*3* %changelog +* Mon Jul 31 2023 Bolehu - 1.5.1-5 +- Fix type of buffer to match zip_random signature + * Fri Nov 06 2020 Ge Wang - 1.5.1-4 - Set help package as libzip package's install require