From 2a35377980a05b6eb7ed47e9979b0ff3849d749f Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Mon, 3 Sep 2012 19:41:36 +0200 Subject: Clean up and make linker scripts more uniform This includes: - fix some comments indent, - add entry point, - align exported symbols, - remove unneeded "." assignments. --- lib/stm32/f1/libopencm3_stm32f1.ld | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'lib/stm32/f1/libopencm3_stm32f1.ld') diff --git a/lib/stm32/f1/libopencm3_stm32f1.ld b/lib/stm32/f1/libopencm3_stm32f1.ld index a64a1f7..f4f8e3b 100644 --- a/lib/stm32/f1/libopencm3_stm32f1.ld +++ b/lib/stm32/f1/libopencm3_stm32f1.ld @@ -30,8 +30,6 @@ ENTRY(reset_handler) /* Define sections. */ SECTIONS { - . = ORIGIN(rom); - .text : { *(.vectors) /* Vector table */ *(.text*) /* Program code */ @@ -42,9 +40,9 @@ SECTIONS } >rom /* - * Another section used by C++ stuff, appears when using newlib with - * 64bit (long long) printf support - */ + * Another section used by C++ stuff, appears when using newlib with + * 64bit (long long) printf support + */ .ARM.extab : { *(.ARM.extab*) } >rom @@ -54,8 +52,6 @@ SECTIONS __exidx_end = .; } >rom - . = ORIGIN(ram); - .data : AT (__exidx_end) { _data = .; *(.data*) /* Read-write initialized data */ @@ -68,7 +64,7 @@ SECTIONS *(COMMON) . = ALIGN(4); _ebss = .; - } >ram AT >rom + } >ram /* * The .eh_frame section appears to be used for C++ exception handling. -- cgit v1.2.3