+1999-10-08 Ian Lance Taylor <ian@zembu.com>
+
+ * elflink.h (elf_merge_symbol): When overriding a weak symbol with
+ a defined symbol in a shared library, clear the DEF_DYNAMIC flag
+ too.
+
Fri Oct 8 13:03:45 1999 Geoffrey Keating <geoffk@cygnus.com>
* elf32-mips.c (mips_elf_calculate_relocation): R_MIPS_LITERAL
/* To make this work we have to frob the flags so that the rest
of the code does not think we are using the regular
definition. */
- h->elf_link_hash_flags &= ~ ELF_LINK_HASH_DEF_REGULAR;
- h->elf_link_hash_flags |= ELF_LINK_HASH_REF_REGULAR;
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+ h->elf_link_hash_flags |= ELF_LINK_HASH_REF_REGULAR;
+ else if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0)
+ h->elf_link_hash_flags |= ELF_LINK_HASH_REF_DYNAMIC;
+ h->elf_link_hash_flags &= ~ (ELF_LINK_HASH_DEF_REGULAR
+ | ELF_LINK_HASH_DEF_DYNAMIC);
/* If H is the target of an indirection, we want the caller to
use H rather than the indirect symbol. Otherwise if we are