* elflink.c (elf_gc_mark_dynamic_ref_symbol): Use !info-executable
authorAlan Modra <amodra@gmail.com>
Sat, 10 Dec 2005 03:31:03 +0000 (03:31 +0000)
committerAlan Modra <amodra@gmail.com>
Sat, 10 Dec 2005 03:31:03 +0000 (03:31 +0000)
to test for linking shared libs, not info->shared.

bfd/ChangeLog
bfd/elflink.c

index 8d89bc16bee6cc24eb9718bd3f47b1944b14a570..1a41fa34444cad57c07de2a52c2fb60b5005721f 100644 (file)
@@ -1,3 +1,8 @@
+2005-12-10  Alan Modra  <amodra@bigpond.net.au>
+
+       * elflink.c (elf_gc_mark_dynamic_ref_symbol):  Use !info-executable
+       to test for linking shared libs, not info->shared.
+
 2005-12-08  Alan Modra  <amodra@bigpond.net.au>
 
        * elf32-ppc.c (struct ppc_elf_link_hash_table): Add emit_stub_syms.
index f31c5c1741a8df186eb6d1eeb8672969631c0a5d..127f002bedcc85b9980dba502e756d3016950aeb 100644 (file)
@@ -9068,7 +9068,7 @@ elf_gc_mark_dynamic_ref_symbol (struct elf_link_hash_entry *h, void *inf)
   if ((h->root.type == bfd_link_hash_defined
        || h->root.type == bfd_link_hash_defweak)
       && (h->ref_dynamic
-         || (info->shared
+         || (!info->executable
              && h->def_regular
              && ELF_ST_VISIBILITY (h->other) != STV_INTERNAL
              && ELF_ST_VISIBILITY (h->other) != STV_HIDDEN)))