summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorLucas Stach <l.stach@pengutronix.de>2014-12-17 11:58:21 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2014-12-17 13:47:05 +0100
commitae2448181adc73f66e31648a8bf3645c4b3f2b47 (patch)
tree0218ee25beb043da294593e6ef276ebbfefb38a0 /arch
parenta1a2d44eedae040fa0e184a815b559714e324a75 (diff)
downloadbarebox-ae2448181adc73f66e31648a8bf3645c4b3f2b47.tar.gz
barebox-ae2448181adc73f66e31648a8bf3645c4b3f2b47.tar.xz
arm: do section garbage collection also with modules enabled
A lot of the arm build (especially PBL stuff) depends on section garbage collection to be enabled. If it is disabled a lot of targets fail to link properly. If module support is enabled garbage collection was disabled on the premise that we throw away too many function which may be needed in later modules. The proper way to keep the functions around for use in modules, which already works, is to annotate them with EXPORT_SYMBOL. As module support is still marked as experimental I think it's reasonable to expect users to make sure all symbols that are used by their modules are properly annotated. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/Makefile2
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index cf81c9c08..193f731e9 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -105,11 +105,9 @@ TEXT_BASE = $(CONFIG_TEXT_BASE)
CPPFLAGS += -DTEXT_BASE=$(TEXT_BASE)
-ifndef CONFIG_MODULES
# Add cleanup flags
CPPFLAGS += -fdata-sections -ffunction-sections
LDFLAGS_barebox += -static --gc-sections
-endif
ifdef CONFIG_RELOCATABLE
LDFLAGS_barebox += -pie