]> oss.titaniummirror.com Git - msp430-binutils.git/blobdiff - ld/scripttempl/avr.sc
Merge commit 'upstream/2.20'
[msp430-binutils.git] / ld / scripttempl / avr.sc
index 7368caf3d0129a27140fc18a3d6ee901cf8b8112..4545b7200959eaa5a0155f24e10b71dd37ff5107 100644 (file)
@@ -5,7 +5,7 @@ OUTPUT_ARCH(${ARCH})
 MEMORY
 {
   text   (rx)   : ORIGIN = 0, LENGTH = $TEXT_LENGTH
-  data   (rw!x) : ORIGIN = 0x800060, LENGTH = $DATA_LENGTH
+  data   (rw!x) : ORIGIN = $DATA_ORIGIN, LENGTH = $DATA_LENGTH
   eeprom (rw!x) : ORIGIN = 0x810000, LENGTH = 64K
 }
 
@@ -72,7 +72,7 @@ SECTIONS
   .rela.plt    ${RELOCATING-0} : { *(.rela.plt)                }
 
   /* Internal text space or external memory.  */
-  .text :
+  .text ${RELOCATING-0} :
   {
     *(.vectors)
     KEEP(*(.vectors))
@@ -168,7 +168,7 @@ SECTIONS
     ${RELOCATING+ PROVIDE (__data_end = .) ; }
   } ${RELOCATING+ > data}
 
-  .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
+  .bss ${RELOCATING-0} :${RELOCATING+ AT (ADDR (.bss))}
   {
     ${RELOCATING+ PROVIDE (__bss_start = .) ; }
     *(.bss)
@@ -181,7 +181,7 @@ SECTIONS
   ${RELOCATING+ __data_load_end = __data_load_start + SIZEOF(.data); }
 
   /* Global data not cleared after reset.  */
-  .noinit ${RELOCATING+ SIZEOF(.bss) + ADDR(.bss)} :
+  .noinit ${RELOCATING-0}:
   {
     ${RELOCATING+ PROVIDE (__noinit_start = .) ; }
     *(.noinit*)