Commit 66463e60dff59716eb323cc1e219189c0fd8671c
Committed by
Albert ARIBAUD
1 parent
363613a08d
Exists in
master
and in
54 other branches
use -ffunction-sections / --gc-sections on IXP42x
Signed-off-by: Michael Schwingen <michael@schwingen.org>
Showing 2 changed files with 9 additions and 4 deletions Side-by-side Diff
arch/arm/cpu/ixp/config.mk
... | ... | @@ -27,6 +27,11 @@ |
27 | 27 | PLATFORM_RELFLAGS += -fno-common -ffixed-r8 -msoft-float -mbig-endian |
28 | 28 | |
29 | 29 | PLATFORM_CPPFLAGS += -mbig-endian -march=armv5te -mtune=strongarm1100 |
30 | + | |
31 | +# -fdata-sections triggers "section .bss overlaps section .rel.dyn" linker error | |
32 | +PLATFORM_RELFLAGS += -ffunction-sections | |
33 | +LDFLAGS_u-boot += --gc-sections | |
34 | + | |
30 | 35 | # ========================================================================= |
31 | 36 | # |
32 | 37 | # Supply options according to compiler version |
arch/arm/cpu/ixp/u-boot.lds
... | ... | @@ -31,8 +31,8 @@ |
31 | 31 | . = ALIGN(4); |
32 | 32 | .text : |
33 | 33 | { |
34 | - arch/arm/cpu/ixp/start.o(.text) | |
35 | - *(.text) | |
34 | + arch/arm/cpu/ixp/start.o(.text*) | |
35 | + *(.text*) | |
36 | 36 | } |
37 | 37 | |
38 | 38 | . = ALIGN(4); |
... | ... | @@ -40,7 +40,7 @@ |
40 | 40 | |
41 | 41 | . = ALIGN(4); |
42 | 42 | .data : { |
43 | - *(.data) | |
43 | + *(.data*) | |
44 | 44 | } |
45 | 45 | |
46 | 46 | . = ALIGN(4); |
... | ... | @@ -67,7 +67,7 @@ |
67 | 67 | |
68 | 68 | .bss __rel_dyn_start (OVERLAY) : { |
69 | 69 | __bss_start = .; |
70 | - *(.bss) | |
70 | + *(.bss*) | |
71 | 71 | . = ALIGN(4); |
72 | 72 | __bss_end__ = .; |
73 | 73 | } |