diff options
author | James Cowgill <james410@cowgill.org.uk> | 2015-05-07 12:03:46 +0300 |
---|---|---|
committer | James Cowgill <james410@cowgill.org.uk> | 2015-05-21 15:44:13 +0300 |
commit | 132f9a8398a21e600612855fae94859b72a513de (patch) | |
tree | 9baa184180ea1b21ecce8863b84d1b50b35dd815 | |
parent | b253ee9554899f0cc8d0c0147e6d110693a140aa (diff) | |
download | CI20_u-boot-132f9a8398a21e600612855fae94859b72a513de.tar.xz |
MIPS: Build SPL with -mno-abicalls and -fomit-frame-pointer
Without these options on some toolchains, the SPL can become too large to fit
in the small amount of memory it has and the link fails.
Thanks to Jaret Cantu for the previous version of this patch.
Signed-off-by: James Cowgill <james410@cowgill.org.uk>
-rw-r--r-- | arch/mips/config.mk | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/mips/config.mk b/arch/mips/config.mk index ab1f6896c..c89279025 100644 --- a/arch/mips/config.mk +++ b/arch/mips/config.mk @@ -46,15 +46,15 @@ PLATFORM_CPPFLAGS += -DCONFIG_MIPS -D__MIPS__ # to RAM, unless we're building SPL which doesn't relocate. $28 is always # used as gp. # -PLATFORM_CPPFLAGS += -G 0 -mabicalls $(ENDIANNESS) +PLATFORM_CPPFLAGS += -G 0 $(ENDIANNESS) PLATFORM_CPPFLAGS += -msoft-float PLATFORM_LDFLAGS += -G 0 -static -n -nostdlib $(ENDIANNESS) PLATFORM_RELFLAGS += -ffunction-sections -fdata-sections LDFLAGS_FINAL += --gc-sections OBJCFLAGS += --remove-section=.dynsym ifdef CONFIG_SPL_BUILD -PLATFORM_CPPFLAGS += -fno-pic +PLATFORM_CPPFLAGS += -fno-pic -mno-abicalls -fomit-frame-pointer else -PLATFORM_CPPFLAGS += -fpic +PLATFORM_CPPFLAGS += -fpic -mabicalls LDFLAGS_FINAL += -pie endif |