* elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
This commit is contained in:
parent
251b8ab932
commit
ce6a773183
|
@ -1,3 +1,8 @@
|
||||||
|
Mon Apr 1 12:35:36 1996 Ian Lance Taylor <ian@cygnus.com>
|
||||||
|
|
||||||
|
* elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
|
||||||
|
defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
|
||||||
|
|
||||||
Sun Mar 31 01:58:41 1996 steve chamberlain <sac@slash.cygnus.com>
|
Sun Mar 31 01:58:41 1996 steve chamberlain <sac@slash.cygnus.com>
|
||||||
|
|
||||||
* peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
|
* peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
|
||||||
|
|
|
@ -1554,6 +1554,18 @@ elf_adjust_dynamic_symbol (h, data)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* If this is a final link, and the symbol was defined as a common
|
||||||
|
symbol in a regular object file, and there was no definition in
|
||||||
|
any dynamic object, then the linker will have allocated space for
|
||||||
|
the symbol in a common section but the ELF_LINK_HASH_DEF_REGULAR
|
||||||
|
flag will not have been set. */
|
||||||
|
if (h->root.type == bfd_link_hash_defined
|
||||||
|
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
|
||||||
|
&& (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) != 0
|
||||||
|
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
|
||||||
|
&& (h->root.u.def.section->owner->flags & DYNAMIC) == 0)
|
||||||
|
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
|
||||||
|
|
||||||
/* If -Bsymbolic was used (which means to bind references to global
|
/* If -Bsymbolic was used (which means to bind references to global
|
||||||
symbols to the definition within the shared object), and this
|
symbols to the definition within the shared object), and this
|
||||||
symbol was defined in a regular object, then it actually doesn't
|
symbol was defined in a regular object, then it actually doesn't
|
||||||
|
|
Loading…
Reference in New Issue