aboutsummaryrefslogtreecommitdiff
path: root/gold/arm.cc
diff options
context:
space:
mode:
authorDoug Kwan <dougkwan@google.com>2011-04-22 21:50:03 +0000
committerDoug Kwan <dougkwan@google.com>2011-04-22 21:50:03 +0000
commitc87e430233549c1670ff335b0d4614f1ea1d7edb (patch)
tree26e7cb53ea81d78cf09f94c1ac88b7e3968e0750 /gold/arm.cc
parent4161fbb015e3216b864fa502a22552d4b999eaf1 (diff)
downloadgdb-c87e430233549c1670ff335b0d4614f1ea1d7edb.zip
gdb-c87e430233549c1670ff335b0d4614f1ea1d7edb.tar.gz
gdb-c87e430233549c1670ff335b0d4614f1ea1d7edb.tar.bz2
2011-04-22 Doug Kwan <dougkwan@google.com>
* arm.cc (Arm_output_section::Arm_output_section): Set SHF_LINK_ORDER flag of a SHT_ARM_EXIDX section. * testsuite/Makefile.am (arm_exidx_test): New test rules. * testsuite/Makefile.in: Regenerate. * testsuite/arm_exidx_test.s: New file. * testsuite/arm_exidx_test.sh: Same.
Diffstat (limited to 'gold/arm.cc')
-rw-r--r--gold/arm.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/gold/arm.cc b/gold/arm.cc
index 6c81d30..541ff59 100644
--- a/gold/arm.cc
+++ b/gold/arm.cc
@@ -1342,9 +1342,13 @@ class Arm_output_section : public Output_section
public:
typedef std::vector<std::pair<Relobj*, unsigned int> > Text_section_list;
+ // We need to force SHF_LINK_ORDER in a SHT_ARM_EXIDX section.
Arm_output_section(const char* name, elfcpp::Elf_Word type,
elfcpp::Elf_Xword flags)
- : Output_section(name, type, flags)
+ : Output_section(name, type,
+ (type == elfcpp::SHT_ARM_EXIDX
+ ? flags | elfcpp::SHF_LINK_ORDER
+ : flags))
{
if (type == elfcpp::SHT_ARM_EXIDX)
this->set_always_keeps_input_sections();