Ignore duplicate indirect symbols generated by the GOLD linker.

Resolves: #1458003
This commit is contained in:
Nick Clifton 2017-06-09 09:23:13 +01:00
parent 54f319436b
commit 803efc2501
2 changed files with 22 additions and 1 deletions

View File

@ -0,0 +1,14 @@
diff -rup binutils.orig/ld/ldmain.c binutils-2.28/ld/ldmain.c
--- binutils.orig/ld/ldmain.c 2017-06-09 09:08:26.954016429 +0100
+++ binutils-2.28/ld/ldmain.c 2017-06-09 09:09:11.307490976 +0100
@@ -923,6 +923,10 @@ multiple_definition (struct bfd_link_inf
obfd = h->u.def.section->owner;
break;
case bfd_link_hash_indirect:
+ /* PR 21074: The GOLD linker can produce multiple indirect
+ refences to the same symbol. These can be ignored. */
+ if (bfd_is_ind_section (nsec))
+ return;
osec = bfd_ind_section_ptr;
oval = 0;
obfd = NULL;

View File

@ -43,7 +43,7 @@
Summary: A GNU collection of binary utilities
Name: %{?cross}binutils%{?_with_debug:-debug}
Version: 2.28
Release: 7%{?dist}
Release: 8%{?dist}
License: GPLv3+
Group: Development/Tools
URL: http://sources.redhat.com/binutils
@ -91,6 +91,8 @@ Patch19: binutils-2.28-ppc-dynamic-relocs.patch
Patch20: binutils-2.28-dynamic-section-warning.patch
# Fix incorrect generation of copy relocs on AArch64.
Patch21: binutils-2.28-aarch64-copy-relocs.patch
# Ignore duplicate indirect symbols generated by GOLD.
Patch22: binutils-2.28-ignore-gold-duplicates.patch
Provides: bundled(libiberty)
@ -233,6 +235,7 @@ using libelf instead of BFD.
%patch19 -p1
%patch20 -p1
%patch21 -p1
%patch22 -p1
# We cannot run autotools as there is an exact requirement of autoconf-2.59.
@ -599,6 +602,10 @@ exit 0
%endif # %{isnative}
%changelog
* Fri Jun 09 2017 Nick Clifton <nickc@redhat.com> 2.28-8
- Ignore duplicate indirect symbols generated by the GOLD linker.
(#1458003)
* Thu Jun 08 2017 Nick Clifton <nickc@redhat.com> 2.28-7
- Eliminate the generation of incorrect dynamic copy relocations on AArch64.
(#1452170)