Rebase to 12.98.

Resolves: RHEL-105572
This commit is contained in:
Nick Clifton 2025-07-25 13:22:26 +01:00
parent cc44c67a5c
commit 06218c8100
3 changed files with 10 additions and 54 deletions

View File

@ -1,28 +0,0 @@
From 916e17ce74aeadc54cadd473f4a33cf4b7a5a784 Mon Sep 17 00:00:00 2001
From: Tulio Magno Quites Machado Filho <tuliom@redhat.com>
Date: Tue, 17 Jun 2025 11:39:12 -0300
Subject: [PATCH] Fix requirement for annobin notes from LLVM/Clang
The LLVM and Clang plugins do not support annobin notes yet.
Disable this test for LLVM and Clang until this feature gets implemented
in order to stop reporting false positives downstream.
---
annocheck/hardened.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/annocheck/hardened.c b/annocheck/hardened.c
index 643e324..aadf291 100644
--- a/annocheck/hardened.c
+++ b/annocheck/hardened.c
@@ -9419,6 +9419,8 @@ finish (annocheck_data * data)
if (RUST_compiler_seen ())
skip (data, TEST_NOTES, SOURCE_FINAL_SCAN, "RUST compiler does not generate annobin notes");
+ if (LLVM_compiler_seen ())
+ skip (data, TEST_NOTES, SOURCE_FINAL_SCAN, "LLVM compiler does not generate annobin notes");
else if (does_not_contain_code (data))
skip (data, TEST_NOTES, SOURCE_FINAL_SCAN, "no code detected, therefore no need for annobin notes");
else if (is_comboot_module (data))
--
2.49.0

View File

@ -1,21 +0,0 @@
--- annobin.orig/gcc-plugin/annobin.cc 2024-11-04 10:17:09.628685926 +0000
+++ annobin-12.72/gcc-plugin/annobin.cc 2024-11-04 10:18:01.542935615 +0000
@@ -540,7 +540,17 @@ annobin_gen_string_note (annobin_functio
if (use_extended_string)
{
- size_t len = strlen (annobin_note_buffer) + 1 + strlen (annobin_input_filename);
+ // For some reason this is happening with RHEL-10 builds.
+ if (annobin_input_filename == NULL)
+ {
+ if (!init_annobin_input_filename ())
+ {
+ ice ("annobin_gen_string_note called without an input filename\n");
+ return;
+ }
+ }
+
+ size_t len = strlen (dst) + 1 + strlen (annobin_input_filename);
if (! is_global (info))
len += strlen (get_func_name (info)) + 1;

View File

@ -1,8 +1,8 @@
Name: annobin
Summary: Annotate and examine compiled binary files
Version: 12.93
Release: 3%{?dist}
Version: 12.98
Release: 1%{?dist}
License: GPL-3.0-or-later AND LGPL-2.0-or-later AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (LGPL-2.0-or-later WITH GCC-exception-2.0) AND GFDL-1.3-or-later
URL: https://sourceware.org/annobin/
# Maintainer: nickc@redhat.com
@ -75,9 +75,6 @@ Source: https://nickc.fedorapeople.org/%{annobin_sources}
# Patch01: annobin-plugin-default-string-notes.patch
# Patch01: annobin-gcc-plugin-input-filename.patch
# Backport of 916e17ce74aea from upstream.
Patch01: 0001-Fix-requirement-for-annobin-notes-from-LLVM-Clang.patch
#---------------------------------------------------------------------------------
# Make sure that the necessary sub-packages are built.
@ -540,6 +537,14 @@ make check
#---------------------------------------------------------------------------------
%changelog
* Fri Jul 25 2025 Nick Clifton <nickc@redhat.com> - 12.98-1
- Rebase to 12.98. (RHEL-105572)
- Improve configure and meson files for consistent builds.
- Annocheck: Delete the temporary debug info directory after the tests have finished.
- Annocheck: Fix bugs in debug rpm location code. Add more glibc exceptions. (RHEL-95216)
- Annocheck: Improve performance with multiple debug info files and multiple files to scan. (#2366180)
- Annocheck: Update heuristic for detecting gcc files to cope with gcc 15. (#2365824)
* Mon Jun 23 2025 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 12.93-3
- Annocheck: Fix requirement for annobin notes from LLVM/Clang (RHEL-93213)