aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-arm.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2004-10-01 12:59:42 +0000
committerNick Clifton <nickc@redhat.com>2004-10-01 12:59:42 +0000
commit40a18ebd3ae910042b4d7bf053a41c247db7cbc1 (patch)
treecd1e24028a8d52668bd1579632901934575f3d52 /gas/config/tc-arm.c
parent14127cc4f2b98a818bef55c977eb3ea11b0ba5ce (diff)
downloadgdb-40a18ebd3ae910042b4d7bf053a41c247db7cbc1.zip
gdb-40a18ebd3ae910042b4d7bf053a41c247db7cbc1.tar.gz
gdb-40a18ebd3ae910042b4d7bf053a41c247db7cbc1.tar.bz2
The patch below adds binutils support for the SHT_ARM_EXIDX, as defined by
the ARM EABI.
Diffstat (limited to 'gas/config/tc-arm.c')
-rw-r--r--gas/config/tc-arm.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index 752cd3c..9770ccd 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -1338,6 +1338,11 @@ arm_elf_change_section (void)
{
flagword flags;
+ /* Link an unlinked unwind index table section to the .text section. */
+ if (elf_section_type (now_seg) == SHT_ARM_EXIDX
+ && elf_linked_to_section (now_seg) == NULL)
+ elf_linked_to_section (now_seg) = text_section;
+
if (!SEG_NORMAL (now_seg))
return;
@@ -1349,6 +1354,15 @@ arm_elf_change_section (void)
mapstate = seg_info (now_seg)->tc_segment_info_data;
}
+
+int
+arm_elf_section_type (const char * str, size_t len)
+{
+ if (len == 5 && strncmp (str, "exidx", 5) == 0)
+ return SHT_ARM_EXIDX;
+
+ return -1;
+}
#else
#define mapping_state(a)
#endif /* OBJ_ELF */