aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-i370.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2003-07-04 01:50:12 +0000
committerAlan Modra <amodra@gmail.com>2003-07-04 01:50:12 +0000
commit3dab13f62bf5909bbae61ad8149e139b622f5f2b (patch)
tree9f7a5f0ee27aeb9623ba8901ab3713ba7183d78b /bfd/elf32-i370.c
parent100f2e98f84dd197660e5b656e7bd7fceaf0729e (diff)
downloadgdb-3dab13f62bf5909bbae61ad8149e139b622f5f2b.zip
gdb-3dab13f62bf5909bbae61ad8149e139b622f5f2b.tar.gz
gdb-3dab13f62bf5909bbae61ad8149e139b622f5f2b.tar.bz2
* elf-bfd.h (_bfd_elf_create_linker_section) Don't declare.
(_bfd_elf_find_pointer_linker_section): Likewise. (bfd_elf32_create_pointer_linker_section): Likewise. (bfd_elf32_finish_pointer_linker_section): Likewise. (bfd_elf64_create_pointer_linker_section): Likewise. (bfd_elf64_finish_pointer_linker_section): Likewise. (_bfd_elf_make_linker_section_rela): Likewise. * elfcode.h (elf_create_pointer_linker_section): Don't define. (elf_finish_pointer_linker_section): Likewise. * elflink.c (_bfd_elf_make_linker_section_rela): Delete. (_bfd_elf_create_linker_section): Move this function.. (_bfd_elf_find_pointer_linker_section): ..and this.. * elflink.h (elf_create_pointer_linker_section): ..and this.. (elf_finish_pointer_linker_section): ..and this.. * elf32-ppc.c: ..to here, renaming to the following, and adjusting calls. (elf_create_linker_section): Convert to C90, tidy. (elf_find_pointer_linker_section): Likewise. (elf_create_pointer_linker_section): Likewise. (elf_finish_pointer_linker_section): Likewise. * elf32-i370.c: Delete #if 0 code.
Diffstat (limited to 'bfd/elf32-i370.c')
-rw-r--r--bfd/elf32-i370.c83
1 files changed, 0 insertions, 83 deletions
diff --git a/bfd/elf32-i370.c b/bfd/elf32-i370.c
index 2eacb81..4a06ac0 100644
--- a/bfd/elf32-i370.c
+++ b/bfd/elf32-i370.c
@@ -290,11 +290,6 @@ static bfd_boolean i370_elf_section_from_shdr
PARAMS ((bfd *, Elf_Internal_Shdr *, const char *));
static bfd_boolean i370_elf_fake_sections
PARAMS ((bfd *, Elf_Internal_Shdr *, asection *));
-#if 0
-static elf_linker_section_t *i370_elf_create_linker_section
- PARAMS ((bfd *abfd, struct bfd_link_info *info,
- enum elf_linker_section_enum));
-#endif
static bfd_boolean i370_elf_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
@@ -434,84 +429,6 @@ i370_elf_fake_sections (abfd, shdr, asect)
return TRUE;
}
-#if 0
-/* Create a special linker section */
-/* XXX hack alert bogus This routine is mostly all junk and almost
- * certainly does the wrong thing. Its here simply because it does
- * just enough to allow glibc-2.1 ld.so to compile & link.
- */
-
-static elf_linker_section_t *
-i370_elf_create_linker_section (abfd, info, which)
- bfd *abfd;
- struct bfd_link_info *info;
- enum elf_linker_section_enum which;
-{
- bfd *dynobj = elf_hash_table (info)->dynobj;
- elf_linker_section_t *lsect;
-
- /* Record the first bfd section that needs the special section */
- if (!dynobj)
- dynobj = elf_hash_table (info)->dynobj = abfd;
-
- /* If this is the first time, create the section */
- lsect = elf_linker_section (dynobj, which);
- if (!lsect)
- {
- elf_linker_section_t defaults;
- static elf_linker_section_t zero_section;
-
- defaults = zero_section;
- defaults.which = which;
- defaults.hole_written_p = FALSE;
- defaults.alignment = 2;
-
- /* Both of these sections are (technically) created by the user
- putting data in them, so they shouldn't be marked
- SEC_LINKER_CREATED.
-
- The linker creates them so it has somewhere to attach their
- respective symbols. In fact, if they were empty it would
- be OK to leave the symbol set to 0 (or any random number), because
- the appropriate register should never be used. */
- defaults.flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY);
-
- switch (which)
- {
- default:
- (*_bfd_error_handler) ("%s: Unknown special linker type %d",
- bfd_archive_filename (abfd),
- (int) which);
-
- bfd_set_error (bfd_error_bad_value);
- return (elf_linker_section_t *)0;
-
- case LINKER_SECTION_SDATA: /* .sdata/.sbss section */
- defaults.name = ".sdata";
- defaults.rel_name = ".rela.sdata";
- defaults.bss_name = ".sbss";
- defaults.sym_name = "_SDA_BASE_";
- defaults.sym_offset = 32768;
- break;
-
- case LINKER_SECTION_SDATA2: /* .sdata2/.sbss2 section */
- defaults.name = ".sdata2";
- defaults.rel_name = ".rela.sdata2";
- defaults.bss_name = ".sbss2";
- defaults.sym_name = "_SDA2_BASE_";
- defaults.sym_offset = 32768;
- defaults.flags |= SEC_READONLY;
- break;
- }
-
- lsect = _bfd_elf_create_linker_section (abfd, info, which, &defaults);
- }
-
- return lsect;
-}
-#endif
-
/* We have to create .dynsbss and .rela.sbss here so that they get mapped
to output sections (just like _bfd_elf_create_dynamic_sections has
to create .dynbss and .rela.bss). */