This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[PATCH] FT32: FT32 linker script cleanup
- From: James Bowman <james dot bowman at ftdichip dot com>
- To: "binutils at sourceware dot org" <binutils at sourceware dot org>
- Date: Tue, 5 Jul 2016 19:17:29 +0000
- Subject: [PATCH] FT32: FT32 linker script cleanup
- Authentication-results: sourceware.org; auth=none
Fix a typo (__PMSIZE was written as __PMSIZE_) and add section alignment
for DATA and BSS.
OK to apply?
James.
ld/ChangeLog:
2016-07-05 James Bowman <james.bowman@ftdichip.com>
* scripttempl/ft32.sc (__PMSIZE): Correct __PMSIZE_.
(DATA): add ALIGN.
(BSS): add ALIGN
---
diff --git a/ld/scripttempl/ft32.sc b/ld/scripttempl/ft32.sc
index 15f8335..7119652 100644
--- a/ld/scripttempl/ft32.sc
+++ b/ld/scripttempl/ft32.sc
@@ -15,7 +15,7 @@ OUTPUT_ARCH(${ARCH})
${LIB_SEARCH_DIRS}
/* Allow the command line to override the memory region sizes. */
-__PMSIZE_ = DEFINED(__PMSIZE) ? __PMSIZE : 256K;
+__PMSIZE = DEFINED(__PMSIZE) ? __PMSIZE : 256K;
__RAMSIZE = DEFINED(__RAMSIZE) ? __RAMSIZE : 64K;
MEMORY
@@ -43,6 +43,7 @@ SECTIONS
*(.rodata)
*(.rodata*)
${RELOCATING+ _edata = . ; }
+ . = ALIGN(4);
} ${RELOCATING+ > ram}
.bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
{
@@ -50,6 +51,7 @@ SECTIONS
*(.bss)
*(COMMON)
${RELOCATING+ _end = . ; }
+ . = ALIGN(4);
} ${RELOCATING+ > ram}
${RELOCATING+ __data_load_start = LOADADDR(.data); }