2002-05-21 H.J. Lu (hjl@gnu.org)
* linker.c (_bfd_generic_link_add_one_symbol): Allow multiple definition.
This commit is contained in:
parent
fcf4f89174
commit
c5a43a5dc5
2 changed files with 34 additions and 28 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2002-05-21 H.J. Lu (hjl@gnu.org)
|
||||||
|
|
||||||
|
* linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
|
||||||
|
definition.
|
||||||
|
|
||||||
2002-05-22 Alan Modra <amodra@bigpond.net.au>
|
2002-05-22 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
* elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
|
* elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
|
||||||
|
|
|
@ -1813,6 +1813,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
|
||||||
/* Fall through. */
|
/* Fall through. */
|
||||||
case MDEF:
|
case MDEF:
|
||||||
/* Handle a multiple definition. */
|
/* Handle a multiple definition. */
|
||||||
|
if (!info->allow_multiple_definition)
|
||||||
{
|
{
|
||||||
asection *msec = NULL;
|
asection *msec = NULL;
|
||||||
bfd_vma mval = 0;
|
bfd_vma mval = 0;
|
||||||
|
@ -1831,8 +1832,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
|
||||||
abort ();
|
abort ();
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Ignore a redefinition of an absolute symbol to the same
|
/* Ignore a redefinition of an absolute symbol to the
|
||||||
value; it's harmless. */
|
same value; it's harmless. */
|
||||||
if (h->type == bfd_link_hash_defined
|
if (h->type == bfd_link_hash_defined
|
||||||
&& bfd_is_abs_section (msec)
|
&& bfd_is_abs_section (msec)
|
||||||
&& bfd_is_abs_section (section)
|
&& bfd_is_abs_section (section)
|
||||||
|
@ -1840,8 +1841,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if (! ((*info->callbacks->multiple_definition)
|
if (! ((*info->callbacks->multiple_definition)
|
||||||
(info, h->root.string, msec->owner, msec, mval, abfd,
|
(info, h->root.string, msec->owner, msec, mval,
|
||||||
section, value)))
|
abfd, section, value)))
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Add table
Reference in a new issue