[PATCH] PR ld/18720: Properly merge hidden versioned symbol
H.J. Lu
hjl.tools@gmail.com
Mon Nov 21 21:09:00 GMT 2016
On Sun, Nov 20, 2016 at 7:09 PM, Alan Modra <amodra@gmail.com> wrote:
> On Wed, Aug 05, 2015 at 07:43:21PM -0700, H.J. Lu wrote:
>> I will check it in this Friday unless there is an objection.
>
> HJ, git 6e33951edc change to elf_link_output_extsym where you
> introduce local_bind, is broken. You can't change global syms to
> STB_LOCAL that late, after _bfd_elf_link_renumber_dynsyms, as otherwise
> you run the risk of ordering STB_LOCAL symbols after global symbols.
> The ELF gABI is clear that "all symbols with STB_LOCAL binding precede
> the weak and global symbols". (It's also wrong to test flags on a
> bfd_link_hash_warning symbol.)
>
> I don't have a testcase for you. I noticed the bug when looking at
> PR20828. Please revert the elf_link_output_extsym change and
> implement by setting forced_local before the last run of
> _bfd_elf_link_renumber_dynsyms.
>
How about this patch?
--
H.J.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Hide-hidden-versioned-symbol-in-executable.patch
Type: text/x-patch
Size: 4917 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20161121/2242010d/attachment.bin>
More information about the Binutils
mailing list