aboutsummaryrefslogtreecommitdiff
path: root/bfd/reloc.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1996-08-30 22:09:51 +0000
committerIan Lance Taylor <ian@airs.com>1996-08-30 22:09:51 +0000
commitc86158e591edd8450f49f8cd75f82e4313d4b6d8 (patch)
treee17ece37589761df543fb981c2c1dd6391dab4e5 /bfd/reloc.c
parent787d66bb4d1d8ded6de1a1f3bf7b3d32ec516b20 (diff)
downloadgdb-c86158e591edd8450f49f8cd75f82e4313d4b6d8.zip
gdb-c86158e591edd8450f49f8cd75f82e4313d4b6d8.tar.gz
gdb-c86158e591edd8450f49f8cd75f82e4313d4b6d8.tar.bz2
Add SH ELF support.
* elf32-sh.c: New file. * elf.c (prep_headers): Handle bfd_arch_sh. * elfcode.h (write_relocs): Handle absolute symbol. * elf-bfd.h (_bfd_elf32_link_read_relocs): Declare. (_bfd_elf64_link_read_relocs): Declare. * elflink.h (NAME(_bfd_elf,link_read_relocs)): Rename from elf_link_read_relocs. Make globally visible. Change all callers. (elf_link_input_bfd): Get external symbols from cache in symtab_hdr->contents. Get contents from cache in elf_section_data. * elfxx-target.h (bfD_elfNN_bfd_relax_section): Only define if not already defined. * reloc.c: Define BFD_RELOC_SH_* relocs. * libbfd-in.h (_bfd_sh_align_load_span): Declare. * coff-sh.c (sh_insns_conflict): Fix a return value. (_bfd_sh_align_load_span): New globally visible function, broken out of sh_align_load. (sh_align_load): Call _bfd_sh_align_load_span. (sh_swap_insns): Change relocs parameter to PTR. * bfd-in2.h, libbfd.h: Rebuild. * targets.c (bfd_elf32_sh_vec): Declare. (bfd_elf32_shl_vec): Declare. * config.bfd (sh-*-elf*): New target. * configure.in (bfd_elf32_sh_vec): New target vector. (bfd_elf32_shl_vec): New target vector. * configure: Rebuild. * Makefile.in: Rebuild dependencies. (BFD32_BACKENDS): Add elf32-sh.o. (BFD32_BACKENDS_CFILES): Add elf32-sh.c. * elf.c (map_sections_to_segments): Check that LMA does not skip a page before checking D_PAGED.
Diffstat (limited to 'bfd/reloc.c')
-rw-r--r--bfd/reloc.c49
1 files changed, 48 insertions, 1 deletions
diff --git a/bfd/reloc.c b/bfd/reloc.c
index d5575ce..4b3e0ee 100644
--- a/bfd/reloc.c
+++ b/bfd/reloc.c
@@ -1,5 +1,5 @@
/* BFD support for handling relocation entries.
- Copyright (C) 1990, 91, 92, 93, 94, 1995 Free Software Foundation, Inc.
+ Copyright (C) 1990, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -2149,10 +2149,57 @@ ENUMX
BFD_RELOC_ARM_OFFSET_IMM8
ENUMX
BFD_RELOC_ARM_HWLITERAL
+ENUMX
+ BFD_RELOC_ARM_THUMB_ADD
+ENUMX
+ BFD_RELOC_ARM_THUMB_IMM
+ENUMX
+ BFD_RELOC_ARM_THUMB_SHIFT
+ENUMX
+ BFD_RELOC_ARM_THUMB_OFFSET
ENUMDOC
These relocs are only used within the ARM assembler. They are not
(at present) written to any object files.
+ENUM
+ BFD_RELOC_SH_PCDISP8BY2
+ENUMX
+ BFD_RELOC_SH_PCDISP12BY2
+ENUMX
+ BFD_RELOC_SH_IMM4
+ENUMX
+ BFD_RELOC_SH_IMM4BY2
+ENUMX
+ BFD_RELOC_SH_IMM4BY4
+ENUMX
+ BFD_RELOC_SH_IMM8
+ENUMX
+ BFD_RELOC_SH_IMM8BY2
+ENUMX
+ BFD_RELOC_SH_IMM8BY4
+ENUMX
+ BFD_RELOC_SH_PCRELIMM8BY2
+ENUMX
+ BFD_RELOC_SH_PCRELIMM8BY4
+ENUMX
+ BFD_RELOC_SH_SWITCH16
+ENUMX
+ BFD_RELOC_SH_SWITCH32
+ENUMX
+ BFD_RELOC_SH_USES
+ENUMX
+ BFD_RELOC_SH_COUNT
+ENUMX
+ BFD_RELOC_SH_ALIGN
+ENUMX
+ BFD_RELOC_SH_CODE
+ENUMX
+ BFD_RELOC_SH_DATA
+ENUMX
+ BFD_RELOC_SH_LABEL
+ENUMDOC
+ Hitachi SH relocs. Not all of these appear in object files.
+
COMMENT
{* start-sanitize-arc *}
ENUM