diff --git a/binutils-2.19.51.0.14-ifunc-ld-s.patch b/binutils-2.19.51.0.14-ifunc-ld-s.patch new file mode 100644 index 0000000..f281910 --- /dev/null +++ b/binutils-2.19.51.0.14-ifunc-ld-s.patch @@ -0,0 +1,34 @@ +2009-11-08 H.J. Lu + + PR ld/10911 + * elflink.c (elf_link_output_extsym): Don't return on + STT_GNU_IFUNC symbol when stripping. + + * ld-ifunc/ifunc-4a-x86.d: New. + +--- bfd/elflink.c ++++ bfd/elflink.c +@@ -8639,9 +8639,11 @@ elf_link_output_extsym (struct elf_link_hash_entry *h, void *data) + strip = FALSE; + + /* If we're stripping it, and it's not a dynamic symbol, there's +- nothing else to do unless it is a forced local symbol. */ ++ nothing else to do unless it is a forced local symbol or a ++ STT_GNU_IFUNC symbol. */ + if (strip + && h->dynindx == -1 ++ && h->type != STT_GNU_IFUNC + && !h->forced_local) + return TRUE; + +--- ld/testsuite/ld-ifunc/ifunc-4a-x86.d ++++ ld/testsuite/ld-ifunc/ifunc-4a-x86.d +@@ -0,0 +1,8 @@ ++#ld: -s ++#readelf: -r --wide ++#target: x86_64-*-* i?86-*-* ++#source: ifunc-4-x86.s ++ ++#... ++[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_[_0-9A-Z]+_IRELATIVE[ ]*[0-9a-f]* ++#pass diff --git a/binutils.spec b/binutils.spec index 05d20b1..5ce1364 100644 --- a/binutils.spec +++ b/binutils.spec @@ -17,7 +17,7 @@ Summary: A GNU collection of binary utilities Name: %{?cross}binutils%{?_with_debug:-debug} Version: 2.19.51.0.14 -Release: 34%{?dist} +Release: 35%{?dist} License: GPLv3+ Group: Development/Tools URL: http://sources.redhat.com/binutils @@ -34,6 +34,7 @@ Patch09: binutils-2.19.51.0.11-moxie.patch Patch10: binutils-2.19.51.0.14-unique-is-global.patch Patch11: binutils-2.19.51.0.14-cxxfilt-java-doc.patch Patch12: binutils-2.19.51.0.14-cfi-sections.patch +Patch13: binutils-2.19.51.0.14-ifunc-ld-s.patch %if 0%{?_with_debug:1} # Define this if you want to skip the strip step and preserve debug info. @@ -109,6 +110,7 @@ to consider using libelf instead of BFD. %patch10 -p0 -b .unique-is-global~ %patch11 -p0 -b .cxxfilt-java-doc~ %patch12 -p0 -b .cfi-sections~ +%patch13 -p0 -b .ifunc-ld-s~ # We cannot run autotools as there is an exact requirement of autoconf-2.59. @@ -376,6 +378,9 @@ exit 0 %endif # %{isnative} %changelog +* Mon Nov 9 2009 Jakub Jelinek 2.19.51.0.14-35 +- Fix ld -s with IRELATIVE relocations. (BZ 533321, PR ld/10911) + * Tue Oct 27 2009 Jan Kratochvil 2.19.51.0.14-34 - Fix rpm --excludedocs (BZ 515922). - Fix spurious scriplet errors by `exit 0'. (BZ 517979, Nick Clifton)