summaryrefslogtreecommitdiffstats
path: root/gold/object.h
diff options
context:
space:
mode:
authorCary Coutant <ccoutant@google.com>2011-08-01 18:25:22 +0000
committerCary Coutant <ccoutant@google.com>2011-08-01 18:25:22 +0000
commit9590bf2544154e40e76e1e4d795d1b21327b0abb (patch)
tree52d41c1f96a4c0d6d0a8e102f61bc8a5f1c50687 /gold/object.h
parent9300444e01cbd7db31985548a0a0eba2b8040b83 (diff)
downloadppe42-binutils-9590bf2544154e40e76e1e4d795d1b21327b0abb.tar.gz
ppe42-binutils-9590bf2544154e40e76e1e4d795d1b21327b0abb.zip
* layout.cc (Layout::set_segment_offsets): Don't realign text
segment if -Ttext was specified. * object.cc (Sized_relobj_file::Sized_relobj_file): Store the ELF file type. * object.h (Sized_relobj_file::e_type): New function. (Sized_relobj_file::e_type_): New data member. * symtab.cc (Symbol_table::add_from_relobj): Don't add section base address for ET_EXEC files. * target.cc (Target::do_make_elf_object_implementation): Allow ET_EXEC files with --just-symbols option.
Diffstat (limited to 'gold/object.h')
-rw-r--r--gold/object.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/gold/object.h b/gold/object.h
index 9c363cd6f7..a389c54a1f 100644
--- a/gold/object.h
+++ b/gold/object.h
@@ -1912,6 +1912,11 @@ class Sized_relobj_file : public Sized_relobj<size, big_endian>
sized_relobj() const
{ return this; }
+ // Return the ELF file type.
+ int
+ e_type() const
+ { return this->e_type_; }
+
// Return the number of symbols. This is only valid after
// Object::add_symbols has been called.
unsigned int
@@ -2504,6 +2509,9 @@ class Sized_relobj_file : public Sized_relobj<size, big_endian>
// General access to the ELF file.
elfcpp::Elf_file<size, big_endian, Object> elf_file_;
+ // Type of ELF file (ET_REL or ET_EXEC). ET_EXEC files are allowed
+ // as input files only for the --just-symbols option.
+ int e_type_;
// Index of SHT_SYMTAB section.
unsigned int symtab_shndx_;
// The number of local symbols.
OpenPOWER on IntegriCloud