aboutsummaryrefslogtreecommitdiff
path: root/ld/scripttempl/elf32msp430.sc
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2013-11-20 16:51:21 +0000
committerNick Clifton <nickc@redhat.com>2013-11-20 16:51:21 +0000
commit925bbbbb989a9bef73a13d6085b2674fe8b90048 (patch)
tree02807a686f04be313d5573e23ea0eb2fb1c5af7b /ld/scripttempl/elf32msp430.sc
parent8986e351a4e4cffcce727d6f612d08a90865358d (diff)
downloadgdb-925bbbbb989a9bef73a13d6085b2674fe8b90048.zip
gdb-925bbbbb989a9bef73a13d6085b2674fe8b90048.tar.gz
gdb-925bbbbb989a9bef73a13d6085b2674fe8b90048.tar.bz2
* scripttempl/elf32msp430.sc (.data): Set the based on the next
free location in the text memory region, not a computation based upon the size of the text section. Orphaned sections or other linker scripts might insert new sections between the .text section and the .data section. * scripttempl/elf32msp430_3.sc (.data): Likewise.
Diffstat (limited to 'ld/scripttempl/elf32msp430.sc')
-rw-r--r--ld/scripttempl/elf32msp430.sc6
1 files changed, 3 insertions, 3 deletions
diff --git a/ld/scripttempl/elf32msp430.sc b/ld/scripttempl/elf32msp430.sc
index c699a91..38df7a4 100644
--- a/ld/scripttempl/elf32msp430.sc
+++ b/ld/scripttempl/elf32msp430.sc
@@ -222,8 +222,8 @@ SECTIONS
${RELOCATING+ _vectors_end = . ; }
} ${RELOCATING+ > vectors}
- .data ${RELOCATING-0} : ${RELOCATING+AT (ADDR (.text) + SIZEOF (.text) + SIZEOF (.rodata))}
- {
+ .data ${RELOCATING-0} :
+ {
${RELOCATING+ PROVIDE (__data_start = .) ; }
${RELOCATING+ PROVIDE (__datastart = .) ; }
${RELOCATING+. = ALIGN(2);}
@@ -242,7 +242,7 @@ SECTIONS
*(.sdata .sdata.* .gnu.linkonce.s.*)
${RELOCATING+. = ALIGN(2);}
${RELOCATING+ _edata = . ; }
- } ${RELOCATING+ > data}
+ } ${RELOCATING+ > data ${RELOCATING+AT> text}}
.bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
{