From 28ff99692e34d7f977082b4ef414591a88505aef Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Sat, 30 Sep 2023 13:56:32 +0200 Subject: [PATCH 1/3] Migrate to new cargo_cbuild and cargo_cinstall macros --- rust-rav1e.spec | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/rust-rav1e.spec b/rust-rav1e.spec index ebec0c9..14f3db7 100644 --- a/rust-rav1e.spec +++ b/rust-rav1e.spec @@ -577,23 +577,13 @@ echo "cargo-c" %build %cargo_build -f binaries,channel-api,unstable -%__cargo cbuild --release \ - --destdir=%{buildroot} \ - --prefix=%{_prefix} \ - --libdir=%{_libdir} \ - --includedir=%{_includedir} \ - --pkgconfigdir=%{_libdir}/pkgconfig +%cargo_cbuild -f binaries,channel-api,unstable %cargo_license_summary -f binaries,channel-api,unstable %{cargo_license -f binaries,channel-api,unstable} > LICENSE.dependencies %install %cargo_install -f binaries,channel-api,unstable -%__cargo cinstall --release \ - --destdir=%{buildroot} \ - --prefix=%{_prefix} \ - --libdir=%{_libdir} \ - --includedir=%{_includedir} \ - --pkgconfigdir=%{_libdir}/pkgconfig +%cargo_cinstall -f binaries,channel-api,unstable rm -v %{buildroot}%{_libdir}/librav1e.a %if %{with check} From 3e5b197f88df63eb624cf96098cfa04b9ea559f6 Mon Sep 17 00:00:00 2001 From: Fabio Valentini Date: Tue, 5 Dec 2023 12:29:19 +0100 Subject: [PATCH 2/3] Compatibility fixes for cargo-c v0.9.26 and newer --- rav1e-fix-metadata-auto.diff | 5 +++-- rav1e-fix-metadata.diff | 41 ++++++++++++++++++------------------ rust-rav1e.spec | 3 +++ 3 files changed, 27 insertions(+), 22 deletions(-) diff --git a/rav1e-fix-metadata-auto.diff b/rav1e-fix-metadata-auto.diff index 6d5048d..9c5a1eb 100644 --- a/rav1e-fix-metadata-auto.diff +++ b/rav1e-fix-metadata-auto.diff @@ -1,6 +1,6 @@ --- rav1e-0.6.6/Cargo.toml 1970-01-01T00:00:01+00:00 -+++ rav1e-0.6.6/Cargo.toml 2023-06-27T18:50:13.590213+00:00 -@@ -342,24 +342,6 @@ ++++ rav1e-0.6.6/Cargo.toml 2023-12-05T15:31:19.481323+00:00 +@@ -342,24 +342,7 @@ unstable = [] wasm = ["wasm-bindgen"] @@ -25,3 +25,4 @@ [target."cfg(unix)".dependencies.signal-hook] version = "0.3" optional = true ++ diff --git a/rav1e-fix-metadata.diff b/rav1e-fix-metadata.diff index 86da400..ad88ab2 100644 --- a/rav1e-fix-metadata.diff +++ b/rav1e-fix-metadata.diff @@ -1,15 +1,16 @@ --- rav1e-0.6.6/Cargo.toml 1970-01-01T00:00:01+00:00 -+++ rav1e-0.6.6/Cargo.toml 2023-06-27T18:52:48.813784+00:00 -@@ -30,7 +30,7 @@ - default-run = "rav1e" - description = "The fastest and safest AV1 encoder" - readme = "README.md" --license = "BSD-2-Clause" -+license = "BSD-2-Clause AND ISC" ++++ rav1e-0.6.6/Cargo.toml 2023-12-05T15:33:39.388912+00:00 +@@ -33,6 +33,9 @@ + license = "BSD-2-Clause" repository = "https://github.com/xiph/rav1e/" ++[package.metadata.capi.library] ++version_suffix_components = 1 ++ [package.metadata.docs.rs] -@@ -72,11 +72,6 @@ + no-default-features = true + +@@ -72,11 +75,6 @@ "unstable", ] @@ -21,7 +22,7 @@ [dependencies.aom-sys] version = "0.3.2" optional = true -@@ -88,7 +83,7 @@ +@@ -88,7 +86,7 @@ version = "0.7" [dependencies.av-metrics] @@ -30,7 +31,7 @@ optional = true default-features = false -@@ -111,7 +106,7 @@ +@@ -111,7 +109,7 @@ version = "1.0" [dependencies.clap] @@ -39,7 +40,7 @@ features = [ "color", "std", -@@ -125,10 +120,6 @@ +@@ -125,10 +123,6 @@ version = "4.0.3" optional = true @@ -50,7 +51,7 @@ [dependencies.console] version = "0.15" optional = true -@@ -191,9 +182,6 @@ +@@ -191,9 +185,6 @@ default-features = false package = "maybe-rayon" @@ -60,7 +61,7 @@ [dependencies.scan_fmt] version = "0.2.3" optional = true -@@ -221,12 +209,8 @@ +@@ -221,12 +212,8 @@ [dependencies.v_frame] version = "0.3.3" @@ -74,7 +75,7 @@ optional = true [dependencies.y4m] -@@ -234,10 +218,7 @@ +@@ -234,10 +221,7 @@ optional = true [dev-dependencies.assert_cmd] @@ -86,7 +87,7 @@ [dev-dependencies.interpolate_name] version = "0.2.2" -@@ -246,13 +227,13 @@ +@@ -246,13 +230,13 @@ version = "7.1.1" [dev-dependencies.predicates] @@ -103,7 +104,7 @@ [dev-dependencies.pretty_assertions] version = "1.3.0" -@@ -271,10 +252,6 @@ +@@ -271,10 +255,6 @@ [dev-dependencies.semver] version = "1.0" @@ -114,7 +115,7 @@ [build-dependencies.cc] version = "1.0" -@@ -294,7 +271,6 @@ +@@ -294,7 +274,6 @@ "nasm-rs", "cc", ] @@ -122,7 +123,7 @@ binaries = [ "ivf", "y4m", -@@ -316,7 +292,6 @@ +@@ -316,7 +295,6 @@ "asm", "threading", "signal_support", @@ -130,7 +131,7 @@ ] desync_finder = ["backtrace"] dump_ivf = ["ivf"] -@@ -324,7 +299,6 @@ +@@ -324,7 +302,6 @@ "byteorder", "image", ] @@ -138,7 +139,7 @@ quick_test = [] scenechange = [] serialize = [ -@@ -335,12 +309,7 @@ +@@ -335,12 +312,7 @@ ] signal_support = ["signal-hook"] threading = ["rayon/threads"] diff --git a/rust-rav1e.spec b/rust-rav1e.spec index 14f3db7..adc703d 100644 --- a/rust-rav1e.spec +++ b/rust-rav1e.spec @@ -33,6 +33,9 @@ Patch: rav1e-fix-metadata-auto.diff # * drop unused and outdated optional clap_lex dependency # * drop WASM-specific wasm-bindgen dependency and wasm feature # * drop unused, benchmark-only criterion dev-dependency +# * compatibility fixes for cargo-c v0.9.26 and newer: +# https://github.com/lu-zero/cargo-c/pull/346 +# https://github.com/lu-zero/cargo-c/pull/352 Patch: rav1e-fix-metadata.diff Patch: 0001-remove-references-to-removed-built-and-rust_hawktrac.patch From 4d6915d12c3880e816a06b4dacc212c9f0561a05 Mon Sep 17 00:00:00 2001 From: MSVSphere Packaging Team Date: Fri, 8 Dec 2023 16:40:14 +0300 Subject: [PATCH 3/3] Change files format --- .gitignore | 10 -- ...s-to-removed-built-and-rust_hawktrac.patch | 0 .../rav1e-fix-metadata-auto.diff | 0 .../rav1e-fix-metadata.diff | 0 rust-rav1e.spec => SPECS/rust-rav1e.spec | 116 +++++++++++++++++- changelog | 53 -------- sources | 1 - 7 files changed, 115 insertions(+), 65 deletions(-) delete mode 100644 .gitignore rename 0001-remove-references-to-removed-built-and-rust_hawktrac.patch => SOURCES/0001-remove-references-to-removed-built-and-rust_hawktrac.patch (100%) rename rav1e-fix-metadata-auto.diff => SOURCES/rav1e-fix-metadata-auto.diff (100%) rename rav1e-fix-metadata.diff => SOURCES/rav1e-fix-metadata.diff (100%) rename rust-rav1e.spec => SPECS/rust-rav1e.spec (79%) delete mode 100644 changelog delete mode 100644 sources diff --git a/.gitignore b/.gitignore deleted file mode 100644 index f73aa3b..0000000 --- a/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -/rav1e-0.3.0.crate -/rav1e-0.3.1.crate -/rav1e-0.3.3.crate -/rav1e-0.3.4.crate -/rav1e-0.4.0-alpha.crate -/rav1e-0.4.0.crate -/rav1e-0.4.1.crate -/rav1e-0.5.0.crate -/rav1e-0.5.1.crate -/rav1e-0.6.6.crate diff --git a/0001-remove-references-to-removed-built-and-rust_hawktrac.patch b/SOURCES/0001-remove-references-to-removed-built-and-rust_hawktrac.patch similarity index 100% rename from 0001-remove-references-to-removed-built-and-rust_hawktrac.patch rename to SOURCES/0001-remove-references-to-removed-built-and-rust_hawktrac.patch diff --git a/rav1e-fix-metadata-auto.diff b/SOURCES/rav1e-fix-metadata-auto.diff similarity index 100% rename from rav1e-fix-metadata-auto.diff rename to SOURCES/rav1e-fix-metadata-auto.diff diff --git a/rav1e-fix-metadata.diff b/SOURCES/rav1e-fix-metadata.diff similarity index 100% rename from rav1e-fix-metadata.diff rename to SOURCES/rav1e-fix-metadata.diff diff --git a/rust-rav1e.spec b/SPECS/rust-rav1e.spec similarity index 79% rename from rust-rav1e.spec rename to SPECS/rust-rav1e.spec index adc703d..967532d 100644 --- a/rust-rav1e.spec +++ b/SPECS/rust-rav1e.spec @@ -1,3 +1,13 @@ +## START: Set by rpmautospec +## (rpmautospec version 0.3.5) +## RPMAUTOSPEC: autorelease, autochangelog +%define autorelease(e:s:pb:n) %{?-p:0.}%{lua: + release_number = 3; + base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); + print(release_number + base_release_number - 1); +}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} +## END: Set by rpmautospec + # Generated by rust2rpm 24 %bcond_without check @@ -595,4 +605,108 @@ rm -v %{buildroot}%{_libdir}/librav1e.a %endif %changelog -%autochangelog +* Tue Dec 05 2023 Fabio Valentini - 0.6.6-3 +- Compatibility fixes for cargo-c v0.9.26 and newer + +* Tue Dec 05 2023 Fabio Valentini - 0.6.6-2 +- Migrate to new cargo_cbuild and cargo_cinstall macros + +* Wed Jun 28 2023 Fabio Valentini - 0.6.6-1 +- Update to version 0.6.6; Fixes RHBZ#2149770 + +* Sun Feb 19 2023 Fabio Valentini - 0.5.1-8 +- Ensure default Rust compiler flags apply to the shared library build + +* Sun Feb 19 2023 Fabio Valentini - 0.5.1-7 +- Disambiguate code which is ambiguous with Rust 1.67+ + +* Sun Feb 19 2023 Fabio Valentini - 0.5.1-6 +- Backport upstream patch to fix UB / crash in test code + +* Mon Aug 08 2022 Fabio Valentini - 0.5.1-5 +- Remove unused dependencies; split off source-only Rust devel package + +* Sat Jul 23 2022 Fedora Release Engineering - 0.5.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Sat Jun 25 2022 Robert-André Mauchin - 0.5.1-3 +- Fix devel package name + +* Thu Jun 23 2022 Robert-André Mauchin - 0.5.1-2 +- Bump dav1d-sys dep + +* Sun Jun 19 2022 Robert-André Mauchin - 0.5.1-1 +- Update to 0.5.1 Close: rhbz#2032033 + +* Tue Feb 22 2022 Fabio Valentini - 0.5.0-6 +- Hack the workaround of the workaround + +* Tue Feb 22 2022 Fabio Valentini - 0.5.0-5 +- Work around codegen issues when compiling doctests with LLVM 13 + +* Mon Feb 21 2022 Fabio Valentini - 0.5.0-4 +- Bump system-deps from 3.1.2 to 6 + +* Tue Feb 15 2022 Zbigniew Jędrzejewski-Szmek - 0.5.0-3 +- Rebuild with package notes + +* Fri Jan 21 2022 Fedora Release Engineering - 0.5.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Sun Nov 21 2021 Robert-André Mauchin - 0.5.0-1 +- Update to 0.5.0 Close: rhbz#1991588 + +* Sat Aug 07 2021 Fabio Valentini - 0.4.1-4 +- Rebuild with crossbeam-deque 0.8.1 / 0.7.4 for CVE-2021-32810 + +* Fri Jul 23 2021 Fedora Release Engineering - 0.4.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Sat Jul 10 12:15:47 CEST 2021 Robert-André Mauchin - 0.4.1-2 +- Add patch to fix https://github.com/xiph/rav1e/issues/2662 + +* Wed Apr 7 17:07:05 CEST 2021 Robert-André Mauchin - 0.4.1-1 +- Update to 0.4.1 +- Close: rhbz#1915864 + +* Mon Mar 29 16:18:27 CEST 2021 Robert-André Mauchin - 0.4.0-1 +- Update to 0.4.0 +- Close: rhbz#1915864 + +* Wed Jan 27 2021 Fedora Release Engineering - 0.4.0~alpha-0.3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Mon Dec 28 13:32:03 CET 2020 Igor Raits - 0.4.0~alpha-0.2 +- Rebuild + +* Wed Dec 09 15:17:53 CET 2020 Robert-André Mauchin - 0.4.0~alpha-0.1 +- Update to 0.4.0~alpha + +* Sun Dec 06 04:37:40 CET 2020 Robert-André Mauchin - 0.3.4-3 +- Rebuild with new cargo-c to fix pkgconfig includedir +- Fix: rhbz#1902211 + +* Tue Oct 20 2020 Fabio Valentini - 0.3.4-2 +- Temporarily skip some broken tests on aarch64. + +* Tue Oct 20 2020 Fabio Valentini - 0.3.4-1 +- Update to version 0.3.4. + +* Wed Aug 26 2020 Josh Stone - 0.3.3-3 +- Bump paste to 1.0 + +* Wed Jul 29 2020 Fedora Release Engineering - 0.3.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Thu Jun 11 2020 Josh Stone - 0.3.3-1 +- Update to 0.3.3 + +* Mon Mar 09 17:45:25 CET 2020 Robert-André Mauchin - 0.3.1-2 +- Fix pkgconfig prefix path + +* Thu Feb 20 21:15:47 CET 2020 Igor Raits - 0.3.1-1 +- Update to 0.3.1 + +* Tue Feb 11 01:28:07 CET 2020 Robert-André Mauchin - 0.3.0-1 +- Initial package + diff --git a/changelog b/changelog deleted file mode 100644 index c0c3cce..0000000 --- a/changelog +++ /dev/null @@ -1,53 +0,0 @@ -* Sat Aug 07 2021 Fabio Valentini - 0.4.1-4 -- Rebuild with crossbeam-deque 0.8.1 / 0.7.4 for CVE-2021-32810 - -* Fri Jul 23 2021 Fedora Release Engineering - 0.4.1-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild - -* Sat Jul 10 12:15:47 CEST 2021 Robert-André Mauchin - 0.4.1-2 -- Add patch to fix https://github.com/xiph/rav1e/issues/2662 - -* Wed Apr 7 17:07:05 CEST 2021 Robert-André Mauchin - 0.4.1-1 -- Update to 0.4.1 -- Close: rhbz#1915864 - -* Mon Mar 29 16:18:27 CEST 2021 Robert-André Mauchin - 0.4.0-1 -- Update to 0.4.0 -- Close: rhbz#1915864 - -* Wed Jan 27 2021 Fedora Release Engineering - 0.4.0~alpha-0.3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild - -* Mon Dec 28 13:32:03 CET 2020 Igor Raits - 0.4.0~alpha-0.2 -- Rebuild - -* Wed Dec 09 15:17:53 CET 2020 Robert-André Mauchin - 0.4.0~alpha-0.1 -- Update to 0.4.0~alpha - -* Sun Dec 06 04:37:40 CET 2020 Robert-André Mauchin - 0.3.4-3 -- Rebuild with new cargo-c to fix pkgconfig includedir -- Fix: rhbz#1902211 - -* Tue Oct 20 2020 Fabio Valentini - 0.3.4-2 -- Temporarily skip some broken tests on aarch64. - -* Tue Oct 20 2020 Fabio Valentini - 0.3.4-1 -- Update to version 0.3.4. - -* Wed Aug 26 2020 Josh Stone - 0.3.3-3 -- Bump paste to 1.0 - -* Wed Jul 29 2020 Fedora Release Engineering - 0.3.3-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - -* Thu Jun 11 2020 Josh Stone - 0.3.3-1 -- Update to 0.3.3 - -* Mon Mar 09 17:45:25 CET 2020 Robert-André Mauchin - 0.3.1-2 -- Fix pkgconfig prefix path - -* Thu Feb 20 21:15:47 CET 2020 Igor Raits - 0.3.1-1 -- Update to 0.3.1 - -* Tue Feb 11 01:28:07 CET 2020 Robert-André Mauchin - 0.3.0-1 -- Initial package diff --git a/sources b/sources deleted file mode 100644 index c005a15..0000000 --- a/sources +++ /dev/null @@ -1 +0,0 @@ -SHA512 (rav1e-0.6.6.crate) = e2c8502da92cb954c587049e544bd136514a5b9f26acaf3430d6e727da4c050de2cabb6a6e0d017ba79194ec45d9078aa7846746e823837373b4ed391db6e70a