From 19f3102caec92fbfc89ecada9dc3dd17ba771408 Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Mon, 1 Mar 2021 19:09:10 +0100 Subject: [PATCH] update to version 0.5.11 --- .gitignore | 1 + port-to-bzip2-0.4.patch | 13 +++++++++++++ rust-zip.spec | 12 +++++++++--- sources | 2 +- zip-fix-metadata.diff | 14 +++++++++++--- 5 files changed, 35 insertions(+), 7 deletions(-) create mode 100644 port-to-bzip2-0.4.patch diff --git a/.gitignore b/.gitignore index 58b8e1a..66cabeb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /zip-0.5.6.crate /zip-0.5.8.crate /zip-0.5.9.crate +/zip-0.5.11.crate diff --git a/port-to-bzip2-0.4.patch b/port-to-bzip2-0.4.patch new file mode 100644 index 0000000..678ca4f --- /dev/null +++ b/port-to-bzip2-0.4.patch @@ -0,0 +1,13 @@ +diff --git a/src/write.rs b/src/write.rs +index bc68817..4099599 100644 +--- a/src/write.rs ++++ b/src/write.rs +@@ -553,7 +553,7 @@ impl GenericZipWriter { + )), + #[cfg(feature = "bzip2")] + CompressionMethod::Bzip2 => { +- GenericZipWriter::Bzip2(BzEncoder::new(bare, bzip2::Compression::Default)) ++ GenericZipWriter::Bzip2(BzEncoder::new(bare, bzip2::Compression::default())) + } + CompressionMethod::Unsupported(..) => { + return Err(ZipError::UnsupportedArchive("Unsupported compression")) diff --git a/rust-zip.spec b/rust-zip.spec index a2cd4e8..daa0ff4 100644 --- a/rust-zip.spec +++ b/rust-zip.spec @@ -5,8 +5,8 @@ %global crate zip Name: rust-%{crate} -Version: 0.5.9 -Release: 2%{?dist} +Version: 0.5.11 +Release: 1%{?dist} Summary: Library to support the reading and writing of zip files # Upstream license specification: MIT @@ -14,8 +14,10 @@ License: MIT URL: https://crates.io/crates/zip Source: %{crates_source} # Initial patched metadata -# * relax flate2 dependency to allow > 1.0.14 +# * relax flate2 dependency to allow > 1.0.14 (do not care about MSRV in Fedora) +# * bump bzip2 from 0.3 to 0.4: https://github.com/zip-rs/zip/pull/202 Patch0: zip-fix-metadata.diff +Patch1: port-to-bzip2-0.4.patch ExclusiveArch: %{rust_arches} %if %{__cargo_skip_build} @@ -146,6 +148,10 @@ which use "time" feature of "%{crate}" crate. %endif %changelog +* Mon Mar 01 2021 Fabio Valentini - 0.5.11-1 +- Update to version 0.5.11. +- Bump to bzip2 0.4. + * Wed Jan 27 2021 Fedora Release Engineering - 0.5.9-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild diff --git a/sources b/sources index cf50801..f646786 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (zip-0.5.9.crate) = d22c079dabc946becc9d4c05fa65b95ae62422e0abcb95ee036415b58fb212c8d0996d71a30a62a32f0d710a8ba04c1d8b856e38ef6d088c6ce7b7f5eb3b563d +SHA512 (zip-0.5.11.crate) = 92e3d05af2f1020383c8573aed6a7d2964604bad74d2d92e5102b9c34185242b44c005e0a081e2517cbbbe4cdc2e78ae86881fda07557b604ece98fb94e383f2 diff --git a/zip-fix-metadata.diff b/zip-fix-metadata.diff index 724a65f..a8bcc95 100644 --- a/zip-fix-metadata.diff +++ b/zip-fix-metadata.diff @@ -1,6 +1,14 @@ ---- zip-0.5.9/Cargo.toml 2020-12-06T23:39:50+00:00 -+++ zip-0.5.9/Cargo.toml 2020-12-07T13:35:45.295316+00:00 -@@ -35,7 +35,7 @@ +--- zip-0.5.11/Cargo.toml 2021-03-01T12:07:05+00:00 ++++ zip-0.5.11/Cargo.toml 2021-03-01T16:50:52.208395+00:00 +@@ -27,14 +27,14 @@ + version = "1.3" + + [dependencies.bzip2] +-version = "0.3" ++version = "0.4" + optional = true + + [dependencies.crc32fast] version = "1.0" [dependencies.flate2]