From 957564c93015991eee194ef0769a3b64b16a2237 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Tue, 4 Sep 2012 08:04:31 +0000 Subject: * powerpc.cc (do_make_elf_object): Allow ET_EXEC files with --just-symbols. --- gold/ChangeLog | 5 +++++ gold/powerpc.cc | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/gold/ChangeLog b/gold/ChangeLog index 163be50..d812165 100644 --- a/gold/ChangeLog +++ b/gold/ChangeLog @@ -1,3 +1,8 @@ +2012-09-04 Andreas Schwab + + * powerpc.cc (do_make_elf_object): Allow ET_EXEC files with + --just-symbols. + 2012-08-31 Alan Modra * powerpc.cc (Powerpc_relobj): Add and use Address typedef. diff --git a/gold/powerpc.cc b/gold/powerpc.cc index 147d660..f4a9385 100644 --- a/gold/powerpc.cc +++ b/gold/powerpc.cc @@ -1149,7 +1149,10 @@ Target_powerpc::do_make_elf_object( off_t offset, const elfcpp::Ehdr& ehdr) { int et = ehdr.get_e_type(); - if (et == elfcpp::ET_REL) + // ET_EXEC files are valid input for --just-symbols/-R, + // and we treat them as relocatable objects. + if (et == elfcpp::ET_REL + || (et == elfcpp::ET_EXEC && input_file->just_symbols())) { Powerpc_relobj* obj = new Powerpc_relobj(name, input_file, offset, ehdr); -- cgit v1.1