Backport commit 88141209e25ce19473ec07d7aac09cc68f06a630 to fix stripping lld linked binaries.
Resolves: RHEL-50536
This commit is contained in:
parent
dfd50d908a
commit
f99cca1db7
15
binutils-relro-padding.patch
Normal file
15
binutils-relro-padding.patch
Normal file
@ -0,0 +1,15 @@
|
||||
--- binutils.orig/bfd/elf.c 2024-07-25 09:01:36.091804849 +0100
|
||||
+++ binutils-2.35.2/bfd/elf.c 2024-07-25 09:02:22.645006725 +0100
|
||||
@@ -2759,6 +2759,12 @@ static const struct bfd_elf_special_sect
|
||||
{ STRING_COMMA_LEN (".rodata"), -2, SHT_PROGBITS, SHF_ALLOC },
|
||||
{ STRING_COMMA_LEN (".rodata1"), 0, SHT_PROGBITS, SHF_ALLOC },
|
||||
{ STRING_COMMA_LEN (".rela"), -1, SHT_RELA, 0 },
|
||||
+ /* .relro_padding is generated by lld. It should not be confused with a
|
||||
+ reloc containing section, because otherwise elf_fake_sections() will
|
||||
+ set the entsize to 8, which may not be an actual multiple of the
|
||||
+ section's size.
|
||||
+ Note - this entry must appear before the ".rel" entry below. */
|
||||
+ { STRING_COMMA_LEN (".relro_padding"), 0, SHT_NOBITS, SHF_ALLOC | SHF_WRITE },
|
||||
{ STRING_COMMA_LEN (".rel"), -1, SHT_REL, 0 },
|
||||
{ NULL, 0, 0, 0, 0 }
|
||||
};
|
@ -2,7 +2,7 @@
|
||||
Summary: A GNU collection of binary utilities
|
||||
Name: binutils%{?_with_debug:-debug}
|
||||
Version: 2.35.2
|
||||
Release: 50%{?dist}
|
||||
Release: 51%{?dist}
|
||||
License: GPLv3+
|
||||
URL: https://sourceware.org/binutils
|
||||
|
||||
@ -461,6 +461,10 @@ Patch70: binutils-prune-lto-messages.patch
|
||||
# Lifetime: Fixed in 2.38
|
||||
Patch71: binutils-relro.patch
|
||||
|
||||
# Purpose: Stop the BFD library from treating the .relro-padding section as a REL section.
|
||||
# Lifetime: Fixed in 2.44
|
||||
Patch72: binutils-relro-padding.patch
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
Provides: bundled(libiberty)
|
||||
@ -1301,6 +1305,9 @@ exit 0
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
%changelog
|
||||
* Thu Jul 25 2024 Nick Clifton <nickc@redhat.com> - 2.35.2-51
|
||||
- Backport commit 88141209e25ce19473ec07d7aac09cc68f06a630 to fix stripping lld linked binaries. (RHEL-50536)
|
||||
|
||||
* Fri Jul 12 2024 Nick Clifton <nickc@redhat.com> - 2.35.2-50
|
||||
- Additional patch (commit 31b4d3a16f200bf04db8439a63b72bba7af4e1be). (RHEL-45873)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user