diff options
author | Doug Kwan <dougkwan@google.com> | 2009-08-18 23:49:29 +0000 |
---|---|---|
committer | Doug Kwan <dougkwan@google.com> | 2009-08-18 23:49:29 +0000 |
commit | f733487b048b9822fb648be60633061d610b40f3 (patch) | |
tree | 4df42b83ffd58eecbf028b2b8ed33ebb487843b5 /gold/dynobj.cc | |
parent | 688805f3b82d345b056810e08842224bfea3a879 (diff) | |
download | gdb-f733487b048b9822fb648be60633061d610b40f3.zip gdb-f733487b048b9822fb648be60633061d610b40f3.tar.gz gdb-f733487b048b9822fb648be60633061d610b40f3.tar.bz2 |
2009-08-18 Doug Kwan <dougkwan@google.com>
* dynobj.cc (Sized_dynobj::setup): Take a Target object instead of
an elcpp::Ehdr as parameter. Adjust call to set_target.
* dynobj.h (Sized_dynobj::setup): Take a Target object instead of
an elfcpp::Ehdr as parameter.
* object.cc (Object::set_target): Remove the version that looks up
a target and sets it.
(Sized_relobj::setup): Take a Target object instead of
an elfcpp::Ehdr as parameter. Adjust call to set_target.
(make_elf_sized_object): Find target and ask target to
make an ELF object.
* object.h: (Object::set_target): Remove the version that looks up
a target and sets it.
(Sized_relobj::setup): Take a Target object instead of
an elfcpp:Ehdr as parameter.
* target.cc: Include dynobj.h.
(Target::do_make_elf_object_implementation): New.
(Target::do_make_elf_object): New.
* target.h (Target::make_elf_object): New template declaration.
(Target::do_make_elf_object): New method declarations.
(Target::do_make_elf_object_implementation): New template declaration.
Diffstat (limited to 'gold/dynobj.cc')
-rw-r--r-- | gold/dynobj.cc | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/gold/dynobj.cc b/gold/dynobj.cc index 8761eaa..df2afeb 100644 --- a/gold/dynobj.cc +++ b/gold/dynobj.cc @@ -83,13 +83,9 @@ Sized_dynobj<size, big_endian>::Sized_dynobj( template<int size, bool big_endian> void -Sized_dynobj<size, big_endian>::setup( - const elfcpp::Ehdr<size, big_endian>& ehdr) +Sized_dynobj<size, big_endian>::setup(Target *target) { - this->set_target(ehdr.get_e_machine(), size, big_endian, - ehdr.get_e_ident()[elfcpp::EI_OSABI], - ehdr.get_e_ident()[elfcpp::EI_ABIVERSION]); - + this->set_target(target); const unsigned int shnum = this->elf_file_.shnum(); this->set_shnum(shnum); } |