Compare commits

...

9 Commits

Author SHA1 Message Date
Benjamin A. Beasley 9e3e98da12 Restore 32-bit/i686 test skips, as upstream’s fix is not complete
5 months ago
Benjamin A. Beasley 25fc46e397 Update to 7.0.0
5 months ago
Benjamin A. Beasley 24bece0978 Patch for OOM in tests on 32-bit platforms
5 months ago
Benjamin A. Beasley 7257d65680 Trivial reformatting in rust2rpm.toml
5 months ago
Benjamin A. Beasley 2e1bec89f1 On 32-bit/i686, skip some tests that fail with OOM
5 months ago
Benjamin A. Beasley 945ad15398 Update to 6.0.0 (close RHBZ#2272914)
5 months ago
Fedora Release Engineering a084881d4f Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
7 months ago
Fabio Valentini fe7a65277d
Update to version 3.5.0; Fixes RHBZ#2269908
11 months ago
Fedora Release Engineering 84e30a79ae Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
1 year ago

3
.gitignore vendored

@ -3,3 +3,6 @@
/brotli-3.3.3.crate /brotli-3.3.3.crate
/brotli-3.3.4.crate /brotli-3.3.4.crate
/brotli-3.4.0.crate /brotli-3.4.0.crate
/brotli-3.5.0.crate
/brotli-6.0.0.crate
/brotli-7.0.0.crate

@ -0,0 +1,13 @@
From c14dfea3af98729663eb46577d00d283d90ef6d1 Mon Sep 17 00:00:00 2001
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
Date: Wed, 2 Oct 2024 07:10:40 -0400
Subject: [PATCH] Remove unwanted executable permission from src/enc/test.rs
---
src/enc/test.rs | 0
1 file changed, 0 insertions(+), 0 deletions(-)
mode change 100755 => 100644 src/enc/test.rs
diff --git a/src/enc/test.rs b/src/enc/test.rs
old mode 100755
new mode 100644

@ -1,11 +1,8 @@
--- brotli-3.4.0/Cargo.toml 1970-01-01T00:00:01+00:00 --- brotli-7.0.0/Cargo.toml 1970-01-01T00:00:01+00:00
+++ brotli-3.4.0/Cargo.toml 2024-01-14T22:09:14.729914+00:00 +++ brotli-7.0.0/Cargo.toml 2024-10-02T12:36:40.453552+00:00
@@ -28,34 +28,35 @@ @@ -36,6 +36,15 @@
"huffman",
"nostd",
] ]
-license = "BSD-3-Clause/MIT" license = "BSD-3-Clause AND MIT"
+license = "BSD-3-Clause"
repository = "https://github.com/dropbox/rust-brotli" repository = "https://github.com/dropbox/rust-brotli"
+exclude = [ +exclude = [
+ "/ci/", + "/ci/",
@ -19,32 +16,3 @@
[profile.release] [profile.release]
lto = true lto = true
incremental = false
-[[bin]]
-name = "brotli"
-doc = false
-
-[[bin]]
-name = "catbrotli"
-doc = false
-
[dependencies.alloc-no-stdlib]
version = "2.0"
[dependencies.alloc-stdlib]
-version = "~0.2"
+version = "0.2"
optional = true
[dependencies.brotli-decompressor]
-version = "~2.5"
+version = "2.5"
default-features = false
[dependencies.sha2]
-version = "~0.10"
+version = "0.10"
optional = true
[features]

@ -1,32 +1,28 @@
# Generated by rust2rpm 25 # Generated by rust2rpm 26
# * tests fail with OOM problems on 32-bit architectures:
# https://github.com/dropbox/rust-brotli/issues/42
%if 0%{?__isa_bits} == 32
%bcond_with check
%else
%bcond_without check %bcond_without check
%endif
%global debug_package %{nil} %global debug_package %{nil}
# prevent executables from being installed
%global cargo_install_bin 0
%global crate brotli %global crate brotli
Name: rust-brotli Name: rust-brotli
Version: 3.4.0 Version: 7.0.0
Release: %autorelease Release: %autorelease
Summary: Brotli compressor and decompressor with no_std support Summary: Brotli compressor and decompressor with no_std support
License: BSD-3-Clause License: BSD-3-Clause AND MIT
URL: https://crates.io/crates/brotli URL: https://crates.io/crates/brotli
Source: %{crates_source} Source: %{crates_source}
# Manually created patch for downstream crate metadata changes # Manually created patch for downstream crate metadata changes
# * fix license in crate metadata: # * Exclude files that are only useful for upstream development:
# https://github.com/dropbox/rust-brotli/issues/41
# * drop unwanted brotli and catbrotli binaries
# * exclude files that are only useful for upstream development:
# https://github.com/dropbox/rust-brotli/pull/43 # https://github.com/dropbox/rust-brotli/pull/43
Patch: brotli-fix-metadata.diff Patch: brotli-fix-metadata.diff
# * Remove unwanted executable permission from src/enc/test.rs
Patch10: https://github.com/dropbox/rust-brotli/pull/219.patch
BuildRequires: cargo-rpm-macros >= 24 BuildRequires: cargo-rpm-macros >= 26
%global _description %{expand: %global _description %{expand:
A brotli compressor and decompressor that with an interface avoiding the A brotli compressor and decompressor that with an interface avoiding the
@ -48,7 +44,8 @@ This package contains library source intended for building other packages which
use the "%{crate}" crate. use the "%{crate}" crate.
%files devel %files devel
%license %{crate_instdir}/LICENSE %license %{crate_instdir}/LICENSE.BSD-3-Clause
%license %{crate_instdir}/LICENSE.MIT
%doc %{crate_instdir}/README.md %doc %{crate_instdir}/README.md
%{crate_instdir}/ %{crate_instdir}/
@ -76,16 +73,16 @@ use the "alloc-stdlib" feature of the "%{crate}" crate.
%files -n %{name}+alloc-stdlib-devel %files -n %{name}+alloc-stdlib-devel
%ghost %{crate_instdir}/Cargo.toml %ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+benchmark-devel %package -n %{name}+billing-devel
Summary: %{summary} Summary: %{summary}
BuildArch: noarch BuildArch: noarch
%description -n %{name}+benchmark-devel %{_description} %description -n %{name}+billing-devel %{_description}
This package contains library source intended for building other packages which This package contains library source intended for building other packages which
use the "benchmark" feature of the "%{crate}" crate. use the "billing" feature of the "%{crate}" crate.
%files -n %{name}+benchmark-devel %files -n %{name}+billing-devel
%ghost %{crate_instdir}/Cargo.toml %ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+disable-timer-devel %package -n %{name}+disable-timer-devel
@ -100,6 +97,18 @@ use the "disable-timer" feature of the "%{crate}" crate.
%files -n %{name}+disable-timer-devel %files -n %{name}+disable-timer-devel
%ghost %{crate_instdir}/Cargo.toml %ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+disallow_large_window_size-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+disallow_large_window_size-devel %{_description}
This package contains library source intended for building other packages which
use the "disallow_large_window_size" feature of the "%{crate}" crate.
%files -n %{name}+disallow_large_window_size-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+external-literal-probability-devel %package -n %{name}+external-literal-probability-devel
Summary: %{summary} Summary: %{summary}
BuildArch: noarch BuildArch: noarch
@ -124,6 +133,42 @@ use the "ffi-api" feature of the "%{crate}" crate.
%files -n %{name}+ffi-api-devel %files -n %{name}+ffi-api-devel
%ghost %{crate_instdir}/Cargo.toml %ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+float64-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+float64-devel %{_description}
This package contains library source intended for building other packages which
use the "float64" feature of the "%{crate}" crate.
%files -n %{name}+float64-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+floating_point_context_mixing-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+floating_point_context_mixing-devel %{_description}
This package contains library source intended for building other packages which
use the "floating_point_context_mixing" feature of the "%{crate}" crate.
%files -n %{name}+floating_point_context_mixing-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+no-stdlib-ffi-binding-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+no-stdlib-ffi-binding-devel %{_description}
This package contains library source intended for building other packages which
use the "no-stdlib-ffi-binding" feature of the "%{crate}" crate.
%files -n %{name}+no-stdlib-ffi-binding-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+pass-through-ffi-panics-devel %package -n %{name}+pass-through-ffi-panics-devel
Summary: %{summary} Summary: %{summary}
BuildArch: noarch BuildArch: noarch
@ -160,6 +205,18 @@ use the "sha2" feature of the "%{crate}" crate.
%files -n %{name}+sha2-devel %files -n %{name}+sha2-devel
%ghost %{crate_instdir}/Cargo.toml %ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+simd-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+simd-devel %{_description}
This package contains library source intended for building other packages which
use the "simd" feature of the "%{crate}" crate.
%files -n %{name}+simd-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+std-devel %package -n %{name}+std-devel
Summary: %{summary} Summary: %{summary}
BuildArch: noarch BuildArch: noarch
@ -199,9 +256,6 @@ use the "vector_scratch_space" feature of the "%{crate}" crate.
%prep %prep
%autosetup -n %{crate}-%{version} -p1 %autosetup -n %{crate}-%{version} -p1
%cargo_prep %cargo_prep
# * remove executable bits from Rust source files:
# https://github.com/dropbox/rust-brotli/pull/40
find -type f -name '*.rs' -executable -exec chmod -x '{}' +
%generate_buildrequires %generate_buildrequires
%cargo_generate_buildrequires %cargo_generate_buildrequires
@ -214,7 +268,26 @@ find -type f -name '*.rs' -executable -exec chmod -x '{}' +
%if %{with check} %if %{with check}
%check %check
%if 0%{?__isa_bits} != 32
%cargo_test %cargo_test
%else
# Few tests fail with OOM on 32bit
# https://github.com/dropbox/rust-brotli/issues/42
# A fix was included in 7.0.0, but it was not entirely successful:
# https://github.com/dropbox/rust-brotli/issues/42#issuecomment-2388527527
skip="${skip-} --skip enc::test::test_roundtrip_10x10y"
skip="${skip-} --skip enc::test::test_roundtrip_64x"
skip="${skip-} --skip enc::test::test_roundtrip_asyoulik"
skip="${skip-} --skip enc::test::test_roundtrip_asyoulik9_5"
skip="${skip-} --skip enc::test::test_roundtrip_backward65536"
skip="${skip-} --skip enc::test::test_roundtrip_compressed_repeated"
skip="${skip-} --skip enc::test::test_roundtrip_monkey"
skip="${skip-} --skip enc::test::test_roundtrip_quickfox"
skip="${skip-} --skip enc::test::test_roundtrip_quickfox_repeated"
skip="${skip-} --skip enc::test::test_roundtrip_ukkonooa"
skip="${skip-} --skip enc::test::test_roundtrip_x"
%cargo_test -- -- --exact ${skip-}
%endif
%endif %endif
%changelog %changelog

@ -1,3 +1,52 @@
[package] [package]
summary = "Brotli compressor and decompressor with no_std support" summary = "Brotli compressor and decompressor with no_std support"
cargo-toml-patch-comments = [
"""\
Exclude files that are only useful for upstream development: \
https://github.com/dropbox/rust-brotli/pull/43\
""",
]
# The brotli binary would conflict with the one provided by the brotli package.
# The catbrotli binary would not, so we *could* install it, but it doesnt seem
# useful enough to bother.
cargo-install-bin = false
[features]
hide = [
# The benchmark feature makes no sense for external users, and would
# require the corresponding feature in the brotli-decompressor crate, which
# in turn would require a test data corpus.
"benchmark",
]
[scripts.check]
pre = [
"%if 0%{?__isa_bits} != 32",
]
post = [
"%else",
"# Few tests fail with OOM on 32bit",
"# https://github.com/dropbox/rust-brotli/issues/42",
"# A fix was included in 7.0.0, but it was not entirely successful:",
"# https://github.com/dropbox/rust-brotli/issues/42#issuecomment-2388527527",
"skip=\"${skip-} --skip enc::test::test_roundtrip_10x10y\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_64x\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_asyoulik\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_asyoulik9_5\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_backward65536\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_compressed_repeated\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_monkey\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_quickfox\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_quickfox_repeated\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_ukkonooa\"",
"skip=\"${skip-} --skip enc::test::test_roundtrip_x\"",
"%cargo_test -- -- --exact ${skip-}",
"%endif",
]
[[package.extra-patches]]
number = 10
file = "https://github.com/dropbox/rust-brotli/pull/219.patch"
comments = [
"Remove unwanted executable permission from src/enc/test.rs",
]

@ -1 +1 @@
SHA512 (brotli-3.4.0.crate) = 4f08f274f1fa00d8b40b713e4deeff0eafdbfe8621c5478777df6efd72690cb214974fc9f8fd3f070b3f587c99e3f4396c2409f7c7289f6c7225238e1f14b302 SHA512 (brotli-7.0.0.crate) = 577b2efc324bf461e06af94b8b509a095a917d4ecb2bfd2f3097ab4663ad699317c2fdb0b470344c762589c75dfac073b828603ce5609295ddf1748a39b75622

Loading…
Cancel
Save