diff --git a/SOURCES/binutils-undefined-unversioned-symbols.patch b/SOURCES/binutils-undefined-unversioned-symbols.patch new file mode 100644 index 0000000..e044a5a --- /dev/null +++ b/SOURCES/binutils-undefined-unversioned-symbols.patch @@ -0,0 +1,28 @@ +diff -rup binutils-2.30/bfd/elflink.c binutils.new/bfd/elflink.c +--- binutils-2.30/bfd/elflink.c 2021-12-09 09:05:54.545468003 +0000 ++++ binutils.new/bfd/elflink.c 2021-12-09 09:03:15.366632301 +0000 +@@ -9980,7 +9980,7 @@ elf_link_output_extsym (struct bfd_hash_ + if (h->verinfo.verdef == NULL + || (elf_dyn_lib_class (h->verinfo.verdef->vd_bfd) + & (DYN_AS_NEEDED | DYN_DT_NEEDED | DYN_NO_NEEDED))) +- iversym.vs_vers = 0; ++ iversym.vs_vers = 1; + else + iversym.vs_vers = h->verinfo.verdef->vd_exp_refno + 1; + } +diff -rup binutils-2.30/ld/testsuite/ld-elfvers/vers16.dsym binutils.new/ld/testsuite/ld-elfvers/vers16.dsym +--- binutils-2.30/ld/testsuite/ld-elfvers/vers16.dsym 2018-01-13 13:31:16.000000000 +0000 ++++ binutils.new/ld/testsuite/ld-elfvers/vers16.dsym 2021-12-09 09:05:03.730791511 +0000 +@@ -1,2 +1,2 @@ + [0-9a-f]+ g +DF (\.text|\.opd|\*ABS\*) [0-9a-f]+( +Base +)? (0x[0-9a-f]+ )?_?show_bar +-[0-9a-f]+ +DF \*UND\* [0-9a-f]+ +(0x[0-9a-f]+ )?_?show_foo ++[0-9a-f]+ +DF \*UND\* [0-9a-f]+ +Base +(0x[0-9a-f]+ )?_?show_foo +diff -rup binutils-2.30/ld/testsuite/ld-elfvers/vers6.dsym binutils.new/ld/testsuite/ld-elfvers/vers6.dsym +--- binutils-2.30/ld/testsuite/ld-elfvers/vers6.dsym 2018-01-13 13:31:16.000000000 +0000 ++++ binutils.new/ld/testsuite/ld-elfvers/vers6.dsym 2021-12-09 09:04:45.778917378 +0000 +@@ -1,4 +1,4 @@ +-[0-9a-f]+ +DF \*UND\* [0-9a-f]+ +(0x[0-9a-f]+ )?_?show_foo ++[0-9a-f]+ +DF \*UND\* [0-9a-f]+ +Base +(0x[0-9a-f]+ )?_?show_foo + [0-9a-f]+ +DF \*UND\* [0-9a-f]+ +VERS_2.0 +(0x[0-9a-f]+ )?_?show_foo + [0-9a-f]+ +DF \*UND\* [0-9a-f]+ +VERS_1.2 +(0x[0-9a-f]+ )?_?show_foo + [0-9a-f]+ +DF \*UND\* [0-9a-f]+ +VERS_1.1 +(0x[0-9a-f]+ )?_?show_foo diff --git a/SPECS/binutils.spec b/SPECS/binutils.spec index 01d35b6..2ca5881 100644 --- a/SPECS/binutils.spec +++ b/SPECS/binutils.spec @@ -43,7 +43,7 @@ Summary: A GNU collection of binary utilities Name: binutils%{?name_cross}%{?_with_debug:-debug} Version: 2.30 -Release: 111%{?dist} +Release: 112%{?dist} License: GPLv3+ URL: https://sourceware.org/binutils @@ -603,6 +603,10 @@ Patch94: binutils-s390x-arch14.patch # Lifetime: Fixed in 2.38 (maybe) Patch95: binutils.unicode.patch +# Purpose: Make undefined unversioned dynamic symbols global rather than local. +# Lifetime: Fixed in 2.37 +Patch96: binutils-undefined-unversioned-symbols.patch + #---------------------------------------------------------------------------- Provides: bundled(libiberty) @@ -835,6 +839,7 @@ using libelf instead of BFD. %patch93 -p1 %patch94 -p1 %patch95 -p1 +%patch96 -p1 # We cannot run autotools as there is an exact requirement of autoconf-2.59. # FIXME - this is no longer true. Maybe try reinstating autotool use ? @@ -1284,6 +1289,9 @@ exit 0 #---------------------------------------------------------------------------- %changelog +* Thu Dec 09 2021 Nick Clifton - 2.30-112 +- Make undefined unversioned dynamic symbols global rather than local. (#2005176) + * Mon Oct 25 2021 Nick Clifton - 2.30-111 - Add ability to control the display of unicode characters. (#2009173)