aboutsummaryrefslogtreecommitdiff
path: root/ld/emultempl/pe.em
diff options
context:
space:
mode:
authorKai Tietz <kai.tietz@onevision.com>2010-09-22 08:03:42 +0000
committerKai Tietz <kai.tietz@onevision.com>2010-09-22 08:03:42 +0000
commitd48749734084702ffe2a535ece1d52f9aa6ac168 (patch)
tree2ea43369c4bb6ce6e18889adeb102c77ffdad5a0 /ld/emultempl/pe.em
parentcb2f80e68a7419ff24651d89699459e6973539d5 (diff)
downloadgdb-d48749734084702ffe2a535ece1d52f9aa6ac168.zip
gdb-d48749734084702ffe2a535ece1d52f9aa6ac168.tar.gz
gdb-d48749734084702ffe2a535ece1d52f9aa6ac168.tar.bz2
2010-09-22 Kai Tietz <kai.tietz@onevision.com>
* emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Add idata to orphan set. * emultempl/pep.em: Likewise. * scripttempl/armcoff.sc: Separate idata and add __IAT_start__ and __IAT_end__ labels. * scripttempl/pe.sc: Likewise. * scripttempl/pep.sc: Likewise.
Diffstat (limited to 'ld/emultempl/pe.em')
-rw-r--r--ld/emultempl/pe.em9
1 files changed, 8 insertions, 1 deletions
diff --git a/ld/emultempl/pe.em b/ld/emultempl/pe.em
index a29f2e3..bb283c1 100644
--- a/ld/emultempl/pe.em
+++ b/ld/emultempl/pe.em
@@ -1939,6 +1939,9 @@ gld_${EMULATION_NAME}_place_orphan (asection *s,
{ ".text",
SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_CODE,
0, 0, 0, 0 },
+ { ".idata",
+ SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_DATA,
+ 0, 0, 0, 0 },
{ ".rdata",
SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_DATA,
0, 0, 0, 0 },
@@ -1952,6 +1955,7 @@ gld_${EMULATION_NAME}_place_orphan (asection *s,
enum orphan_save_index
{
orphan_text = 0,
+ orphan_idata,
orphan_rodata,
orphan_data,
orphan_bss
@@ -1985,7 +1989,10 @@ gld_${EMULATION_NAME}_place_orphan (asection *s,
else if ((s->flags & SEC_READONLY) == 0)
place = &hold[orphan_data];
else if ((s->flags & SEC_CODE) == 0)
- place = &hold[orphan_rodata];
+ {
+ place = (!strncmp (secname, ".idata\$", 7) ? &hold[orphan_idata]
+ : &hold[orphan_rodata]);
+ }
else
place = &hold[orphan_text];