diff options
author | Alan Modra <amodra@gmail.com> | 2013-03-18 02:47:03 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2013-03-18 02:47:03 +0000 |
commit | ffa9430db119a35786d64ffa50af9c2c368d210f (patch) | |
tree | 5dfa83c0fe14863d865cc98001560a5365108836 /bfd/elflink.c | |
parent | f7f9535d8d2073ca2040997a16f17944e05ec940 (diff) | |
download | gdb-ffa9430db119a35786d64ffa50af9c2c368d210f.zip gdb-ffa9430db119a35786d64ffa50af9c2c368d210f.tar.gz gdb-ffa9430db119a35786d64ffa50af9c2c368d210f.tar.bz2 |
PR ld/12549
bfd/
* elflink.c (elf_link_add_object_symbols): Exclude weak refs when
considering whether an --as-needed library is needed.
ld/
* ld.texinfo (--as-needed): Update.
ld/testsuite/
* ld-elf/pr14862.out: Expect no output.
Diffstat (limited to 'bfd/elflink.c')
-rw-r--r-- | bfd/elflink.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bfd/elflink.c b/bfd/elflink.c index ba65f21..8055d26 100644 --- a/bfd/elflink.c +++ b/bfd/elflink.c @@ -4482,10 +4482,10 @@ error_free_dyn: if (!add_needed && definition && ((dynsym - && h->ref_regular + && h->ref_regular_nonweak && (undef_bfd == NULL || (undef_bfd->flags & BFD_PLUGIN) == 0)) - || (h->ref_dynamic + || (h->ref_dynamic_nonweak && (elf_dyn_lib_class (abfd) & DYN_AS_NEEDED) != 0 && !on_needed_list (elf_dt_name (abfd), htab->needed)))) { |