diff options
author | Ian Lance Taylor <iant@google.com> | 2008-02-06 08:13:50 +0000 |
---|---|---|
committer | Ian Lance Taylor <iant@google.com> | 2008-02-06 08:13:50 +0000 |
commit | 6a74a71947df73c828f073af0dcad0c323dcd8c4 (patch) | |
tree | 19103071382f3c094d30ea8fa6e8d8bbc0af1031 /gold/layout.h | |
parent | 0797561a54769f4d8217c1f141858380025b0094 (diff) | |
download | gdb-6a74a71947df73c828f073af0dcad0c323dcd8c4.zip gdb-6a74a71947df73c828f073af0dcad0c323dcd8c4.tar.gz gdb-6a74a71947df73c828f073af0dcad0c323dcd8c4.tar.bz2 |
Initial -r support.
Diffstat (limited to 'gold/layout.h')
-rw-r--r-- | gold/layout.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/gold/layout.h b/gold/layout.h index d7f5965..e050df3 100644 --- a/gold/layout.h +++ b/gold/layout.h @@ -100,6 +100,29 @@ class Layout const char* name, const elfcpp::Shdr<size, big_endian>& shdr, unsigned int reloc_shndx, unsigned int reloc_type, off_t* offset); + // Layout an input reloc section when doing a relocatable link. The + // section is RELOC_SHNDX in OBJECT, with data in SHDR. + // DATA_SECTION is the reloc section to which it refers. RR is the + // relocatable information. + template<int size, bool big_endian> + Output_section* + layout_reloc(Sized_relobj<size, big_endian>* object, + unsigned int reloc_shndx, + const elfcpp::Shdr<size, big_endian>& shdr, + Output_section* data_section, + Relocatable_relocs* rr); + + // Layout a group section when doing a relocatable link. + template<int size, bool big_endian> + void + layout_group(Symbol_table* symtab, + Sized_relobj<size, big_endian>* object, + unsigned int group_shndx, + const char* group_section_name, + const char* signature, + const elfcpp::Shdr<size, big_endian>& shdr, + const elfcpp::Elf_Word* contents); + // Like layout, only for exception frame sections. OBJECT is an // object file. SYMBOLS is the contents of the symbol table // section, with size SYMBOLS_SIZE. SYMBOL_NAMES is the contents of @@ -413,6 +436,11 @@ class Layout off_t set_segment_offsets(const Target*, Output_segment*, unsigned int* pshndx); + // Set the file offsets of the sections when doing a relocatable + // link. + off_t + set_relocatable_section_offsets(Output_data*, unsigned int* pshndx); + // Set the final file offsets of all the sections not associated // with a segment. We set section offsets in three passes: the // first handles all allocated sections, the second sections that |