From 9649ceb33890c64129acc8bd3ef991cdd69b9e49 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 2 May 2024 09:42:49 -0700 Subject: [PATCH] Fix the coverage-dump tool for tests. Resolves: RHEL-30084 --- 0001-Step-all-bootstrap-cfgs-forward.patch | 26 ++++++++++++++++++++++ rust.spec | 9 +++++++- 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 0001-Step-all-bootstrap-cfgs-forward.patch diff --git a/0001-Step-all-bootstrap-cfgs-forward.patch b/0001-Step-all-bootstrap-cfgs-forward.patch new file mode 100644 index 0000000..bd0cd02 --- /dev/null +++ b/0001-Step-all-bootstrap-cfgs-forward.patch @@ -0,0 +1,26 @@ +From 9a5034a20ed8b055dc615271f9d9cf27f9e494f0 Mon Sep 17 00:00:00 2001 +From: Mark Rousskov +Date: Mon, 5 Feb 2024 07:34:48 -0500 +Subject: [PATCH] Step all bootstrap cfgs forward + +This also takes care of other bootstrap-related changes. +--- + src/tools/coverage-dump/src/covfun.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/tools/coverage-dump/src/covfun.rs b/src/tools/coverage-dump/src/covfun.rs +index 3a5866dea3e0..49e3a6ed5838 100644 +--- a/src/tools/coverage-dump/src/covfun.rs ++++ b/src/tools/coverage-dump/src/covfun.rs +@@ -219,7 +219,7 @@ pub(crate) fn decode(input: u32) -> Option { + enum MappingKind { + Code(CovTerm), + Gap(CovTerm), +- Expansion(u32), ++ Expansion(#[allow(dead_code)] u32), + Skip, + // Using raw identifiers here makes the dump output a little bit nicer + // (via the derived Debug), at the expense of making this tool's source +-- +2.44.0 + diff --git a/rust.spec b/rust.spec index 7432187..dd5581b 100644 --- a/rust.spec +++ b/rust.spec @@ -1,6 +1,6 @@ Name: rust Version: 1.77.2 -Release: 2%{?dist} +Release: 3%{?dist} Summary: The Rust Programming Language License: (Apache-2.0 OR MIT) AND (Artistic-2.0 AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0 AND Unicode-DFS-2016) # ^ written as: (rust itself) and (bundled libraries) @@ -172,6 +172,9 @@ Patch12: 0001-test-don-t-compress-test-registry-crates.patch # https://github.com/rust-lang/rust-clippy/pull/12682 Patch13: 0001-The-multiple_unsafe_ops_per_block-test-needs-asm.patch +# https://github.com/rust-lang/rust/pull/120676 (partial) +Patch14: 0001-Step-all-bootstrap-cfgs-forward.patch + ### RHEL-specific patches below ### # Simple rpm macros for rust-toolset (as opposed to full rust-packaging) @@ -636,6 +639,7 @@ rm -rf %{wasi_libc_dir}/dlmalloc/ %patch -P11 -p1 %patch -P12 -p1 -d src/tools/cargo %patch -P13 -p1 -d src/tools/clippy +%patch -P14 -p1 %if %with disabled_libssh2 %patch -P100 -p1 @@ -1120,6 +1124,9 @@ rm -rf "./build/%{rust_triple}/stage2-tools/%{rust_triple}/cit/" %changelog +* Thu May 02 2024 Josh Stone - 1.77.2-3 +- Fix the coverage-dump tool for tests. + * Tue Apr 30 2024 Josh Stone - 1.77.2-2 - Use bundled sqlite3 when the system version is too old.