From 15ac63cefdfb5345cfb7b45f043b053e8d19576b Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Mon, 18 Jul 2022 10:39:22 +0200 Subject: [PATCH] Update to version 0.1.7; Fixes RHBZ#2077517 --- .gitignore | 1 + rust-weezl.spec | 64 +++++++++++++++++++++-------------------- sources | 2 +- weezl-fix-metadata.diff | 12 ++++++++ 4 files changed, 47 insertions(+), 32 deletions(-) create mode 100644 weezl-fix-metadata.diff diff --git a/.gitignore b/.gitignore index 911d120..5ebbee6 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ /weezl-0.1.3.crate /weezl-0.1.4.crate /weezl-0.1.5.crate +/weezl-0.1.7.crate diff --git a/rust-weezl.spec b/rust-weezl.spec index 7be5ec0..266373d 100644 --- a/rust-weezl.spec +++ b/rust-weezl.spec @@ -1,10 +1,10 @@ -# Generated by rust2rpm 17 +# Generated by rust2rpm 21 %bcond_without check %global crate weezl Name: rust-%{crate} -Version: 0.1.5 +Version: 0.1.7 Release: %autorelease Summary: Fast LZW compression and decompression @@ -12,30 +12,30 @@ Summary: Fast LZW compression and decompression License: MIT or ASL 2.0 URL: https://crates.io/crates/weezl Source: %{crates_source} +# Initial patched metadata +# * drop unused, benchmark-only criterion dev-dependency to speed up builds +Patch0: weezl-fix-metadata.diff ExclusiveArch: %{rust_arches} -%if %{__cargo_skip_build} -BuildArch: noarch -%endif -BuildRequires: rust-packaging +BuildRequires: rust-packaging >= 21 %global _description %{expand: Fast LZW compression and decompression.} %description %{_description} -%if ! %{__cargo_skip_build} %package -n %{crate} Summary: %{summary} %description -n %{crate} %{_description} %files -n %{crate} -%license LICENSE-APACHE LICENSE-MIT -%doc README.md Changes.md +%license LICENSE-APACHE +%license LICENSE-MIT +%doc Changes.md +%doc README.md %{_bindir}/lzw -%endif %package devel Summary: %{summary} @@ -43,13 +43,15 @@ BuildArch: noarch %description devel %{_description} -This package contains library source intended for building other packages -which use "%{crate}" crate. +This package contains library source intended for building other packages which +use the "%{crate}" crate. %files devel -%license LICENSE-APACHE LICENSE-MIT -%doc README.md Changes.md -%{cargo_registry}/%{crate}-%{version_no_tilde}/ +%license %{crate_instdir}/LICENSE-APACHE +%license %{crate_instdir}/LICENSE-MIT +%doc %{crate_instdir}/Changes.md +%doc %{crate_instdir}/README.md +%{crate_instdir}/ %package -n %{name}+default-devel Summary: %{summary} @@ -57,11 +59,11 @@ BuildArch: noarch %description -n %{name}+default-devel %{_description} -This package contains library source intended for building other packages -which use "default" feature of "%{crate}" crate. +This package contains library source intended for building other packages which +use the "default" feature of the "%{crate}" crate. %files -n %{name}+default-devel -%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml +%ghost %{crate_instdir}/Cargo.toml %package -n %{name}+alloc-devel Summary: %{summary} @@ -69,11 +71,11 @@ BuildArch: noarch %description -n %{name}+alloc-devel %{_description} -This package contains library source intended for building other packages -which use "alloc" feature of "%{crate}" crate. +This package contains library source intended for building other packages which +use the "alloc" feature of the "%{crate}" crate. %files -n %{name}+alloc-devel -%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml +%ghost %{crate_instdir}/Cargo.toml %package -n %{name}+async-devel Summary: %{summary} @@ -81,11 +83,11 @@ BuildArch: noarch %description -n %{name}+async-devel %{_description} -This package contains library source intended for building other packages -which use "async" feature of "%{crate}" crate. +This package contains library source intended for building other packages which +use the "async" feature of the "%{crate}" crate. %files -n %{name}+async-devel -%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml +%ghost %{crate_instdir}/Cargo.toml %package -n %{name}+futures-devel Summary: %{summary} @@ -93,11 +95,11 @@ BuildArch: noarch %description -n %{name}+futures-devel %{_description} -This package contains library source intended for building other packages -which use "futures" feature of "%{crate}" crate. +This package contains library source intended for building other packages which +use the "futures" feature of the "%{crate}" crate. %files -n %{name}+futures-devel -%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml +%ghost %{crate_instdir}/Cargo.toml %package -n %{name}+std-devel Summary: %{summary} @@ -105,11 +107,11 @@ BuildArch: noarch %description -n %{name}+std-devel %{_description} -This package contains library source intended for building other packages -which use "std" feature of "%{crate}" crate. +This package contains library source intended for building other packages which +use the "std" feature of the "%{crate}" crate. %files -n %{name}+std-devel -%ghost %{cargo_registry}/%{crate}-%{version_no_tilde}/Cargo.toml +%ghost %{crate_instdir}/Cargo.toml %prep %autosetup -n %{crate}-%{version_no_tilde} -p1 @@ -126,7 +128,7 @@ which use "std" feature of "%{crate}" crate. %if %{with check} %check -# files include!d in encode/decode tests are not included in the published crate +# * files needed for encode/decode tests are not included in published crates %cargo_test -- --doc %endif diff --git a/sources b/sources index 37ae560..c1ade5e 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (weezl-0.1.5.crate) = 1fe4352dc8c773ac1297ba23ca3236dece6cec44887116afb1b3760dd0cf3ffcf5faae3aa98814775fddc38032c97c26a14684b47e7aa9deaecafe8c908e0735 +SHA512 (weezl-0.1.7.crate) = 3fd8cb01dde494371df57001c97be90418b642ba88b0945cd98f973a4498743b83d383bcdfc8884db1da75271aeef4ce3b418e425f23690f12a5cc645c418e90 diff --git a/weezl-fix-metadata.diff b/weezl-fix-metadata.diff new file mode 100644 index 0000000..239d401 --- /dev/null +++ b/weezl-fix-metadata.diff @@ -0,0 +1,12 @@ +--- weezl-0.1.7/Cargo.toml 1970-01-01T00:00:01+00:00 ++++ weezl-0.1.7/Cargo.toml 2022-07-18T08:34:15.942522+00:00 +@@ -72,9 +72,6 @@ + optional = true + default-features = false + +-[dev-dependencies.criterion] +-version = "0.3.1" +- + [dev-dependencies.tokio] + version = "1" + features = [