forked from Imagelibrary/binutils-gdb
* Makefile.am: Remove all mention of elflink.h.
* Makefile.in: Regenerate. * bfd-in.h (bfd_elf_discard_info): Declare. (bfd_elf32_discard_info, bfd_elf64_discard_info): Delete. * bfd-in2.h: Regenerate. * elf-bfd.h (bfd_elf32_print_symbol, bfd_elf64_print_symbol, bfd_elf32_link_record_dynamic_symbol, bfd_elf64_link_record_dynamic_symbol, _bfd_elf_link_record_dynamic_symbol, bfd_elf32_bfd_final_link, bfd_elf64_bfd_final_link, elf_link_record_local_dynamic_symbol, _bfd_elf32_link_record_local_dynamic_symbol, _bfd_elf64_link_record_local_dynamic_symbol, _bfd_elf32_gc_sections, _bfd_elf32_gc_common_finalize_got_offsets, _bfd_elf32_gc_common_final_link, _bfd_elf64_gc_common_final_link, _bfd_elf32_gc_record_vtinherit, _bfd_elf32_gc_record_vtentry, _bfd_elf64_gc_sections, _bfd_elf64_gc_common_finalize_got_offsets, _bfd_elf64_gc_record_vtinherit, _bfd_elf64_gc_record_vtentry, _bfd_elf32_reloc_symbol_deleted_p, _bfd_elf64_reloc_symbol_deleted_p): Delete. (bfd_elf_link_record_dynamic_symbol, bfd_elf_link_record_local_dynamic_symbol, bfd_elf_final_link, bfd_elf_gc_sections, bfd_elf_gc_record_vtinherit, bfd_elf_gc_record_vtentry, bfd_elf_gc_common_finalize_got_offsets, bfd_elf_gc_common_final_link, bfd_elf_reloc_symbol_deleted_p): Declare. (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define. * elf32-arm.h: Update for changed function names. Remove local WILL_CALL_FINISH_DYNAMIC_SECTION define. * elf-hppa.h, elf-m10300.c, elf32-cris.c, elf32-d10v.c, elf32-dlx.c, * elf32-fr30.c, elf32-frv.c, elf32-h8300.c, elf32-hppa.c, elf32-i386.c, * elf32-iq2000.c, elf32-m32r.c, elf32-m68hc1x.c, elf32-m68k.c, * elf32-mcore.c, elf32-openrisc.c, elf32-ppc.c, elf32-s390.c, * elf32-sh.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c, * elf32-xstormy16.c, elf32-xtensa.c, elf64-alpha.c, elf64-hppa.c, * elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c, elf64-sparc.c, * elf64-x86-64.c, elfxx-ia64.c, elfxx-mips.c, elfxx-target.h: Likewise. * elfxx-target.h (bfd_elfNN_bfd_final_link): Define. (bfd_elfNN_print_symbol): Define. * elfcode.h: Don't include elflink.h. (elf_bfd_discard_info, elf_reloc_symbol_deleted_p, elf_link_record_dynamic_symbol, elf_bfd_final_link, elf_gc_sections, elf_gc_common_finalize_got_offsets, elf_gc_common_final_link, elf_gc_record_vtinherit, elf_gc_record_vtentry, elf_link_record_local_dynamic_symbol): Don't define. * elflink.c: Update for changed function names. Move elflink.h code here. * elflink.h: Delete file. * po/SRC-POTFILES.in: Regenerate. * po/bfd.pot: Regenerate. doc/ * bfdint.texi: Remove all mention of elflink.h.
This commit is contained in:
@@ -1199,16 +1199,14 @@ elf32_hppa_check_relocs (bfd *abfd,
|
||||
/* This relocation describes the C++ object vtable hierarchy.
|
||||
Reconstruct it for later use during GC. */
|
||||
case R_PARISC_GNU_VTINHERIT:
|
||||
if (!_bfd_elf32_gc_record_vtinherit (abfd, sec,
|
||||
&h->elf, rel->r_offset))
|
||||
if (!bfd_elf_gc_record_vtinherit (abfd, sec, &h->elf, rel->r_offset))
|
||||
return FALSE;
|
||||
continue;
|
||||
|
||||
/* This relocation describes which C++ vtable entries are actually
|
||||
used. Record for later use during GC. */
|
||||
case R_PARISC_GNU_VTENTRY:
|
||||
if (!_bfd_elf32_gc_record_vtentry (abfd, sec,
|
||||
&h->elf, rel->r_addend))
|
||||
if (!bfd_elf_gc_record_vtentry (abfd, sec, &h->elf, rel->r_addend))
|
||||
return FALSE;
|
||||
continue;
|
||||
|
||||
@@ -1621,17 +1619,6 @@ elf32_hppa_hide_symbol (struct bfd_link_info *info,
|
||||
}
|
||||
}
|
||||
|
||||
/* This is the condition under which elf32_hppa_finish_dynamic_symbol
|
||||
will be called from elflink.h. If elflink.h doesn't call our
|
||||
finish_dynamic_symbol routine, we'll need to do something about
|
||||
initializing any .plt and .got entries in elf32_hppa_relocate_section. */
|
||||
#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
|
||||
((DYN) \
|
||||
&& ((INFO)->shared \
|
||||
|| ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
|
||||
&& ((H)->dynindx != -1 \
|
||||
|| ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
|
||||
|
||||
/* Adjust a symbol defined by a dynamic object and referenced by a
|
||||
regular object. The current definition is in some section of the
|
||||
dynamic object, but we're not including those sections. We have to
|
||||
@@ -1803,11 +1790,11 @@ allocate_plt_static (struct elf_link_hash_entry *h, void *inf)
|
||||
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0
|
||||
&& h->type != STT_PARISC_MILLI)
|
||||
{
|
||||
if (! bfd_elf32_link_record_dynamic_symbol (info, h))
|
||||
if (! bfd_elf_link_record_dynamic_symbol (info, h))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, h))
|
||||
if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared, h))
|
||||
{
|
||||
/* Allocate these later. From this point on, h->plabel
|
||||
means that the plt entry is only used by a plabel.
|
||||
@@ -1881,7 +1868,7 @@ allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
|
||||
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0
|
||||
&& h->type != STT_PARISC_MILLI)
|
||||
{
|
||||
if (! bfd_elf32_link_record_dynamic_symbol (info, h))
|
||||
if (! bfd_elf_link_record_dynamic_symbol (info, h))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -1952,7 +1939,7 @@ allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
|
||||
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0
|
||||
&& h->type != STT_PARISC_MILLI)
|
||||
{
|
||||
if (! bfd_elf32_link_record_dynamic_symbol (info, h))
|
||||
if (! bfd_elf_link_record_dynamic_symbol (info, h))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -3005,7 +2992,7 @@ static bfd_boolean
|
||||
elf32_hppa_final_link (bfd *abfd, struct bfd_link_info *info)
|
||||
{
|
||||
/* Invoke the regular ELF linker to do all the work. */
|
||||
if (!bfd_elf32_bfd_final_link (abfd, info))
|
||||
if (!bfd_elf_final_link (abfd, info))
|
||||
return FALSE;
|
||||
|
||||
/* If we're producing a final executable, sort the contents of the
|
||||
@@ -3479,7 +3466,8 @@ elf32_hppa_relocate_section (bfd *output_bfd,
|
||||
|
||||
off = h->elf.got.offset;
|
||||
dyn = htab->elf.dynamic_sections_created;
|
||||
if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, &h->elf))
|
||||
if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared,
|
||||
&h->elf))
|
||||
{
|
||||
/* If we aren't going to call finish_dynamic_symbol,
|
||||
then we need to handle initialisation of the .got
|
||||
@@ -3571,7 +3559,8 @@ elf32_hppa_relocate_section (bfd *output_bfd,
|
||||
if (h != NULL)
|
||||
{
|
||||
off = h->elf.plt.offset;
|
||||
if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, &h->elf))
|
||||
if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared,
|
||||
&h->elf))
|
||||
{
|
||||
/* In a non-shared link, adjust_dynamic_symbols
|
||||
isn't called for symbols forced local. We
|
||||
|
||||
Reference in New Issue
Block a user