summaryrefslogtreecommitdiff
path: root/Rules.mak
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2015-12-06 17:53:50 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2015-12-09 07:50:58 +0100
commit4904b4f317c7250107925ff47f38fc31b4aaaddd (patch)
tree6137806dcca275174fbb9e4e3fec1cddf6bec321 /Rules.mak
parentafe0dd3c88d8a4c584dcaf68c5b7590a730cf3e6 (diff)
Avoid unnecessary rebuilds due to compiler flag changes
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
Diffstat (limited to 'Rules.mak')
-rw-r--r--Rules.mak6
1 files changed, 3 insertions, 3 deletions
diff --git a/Rules.mak b/Rules.mak
index 59b408b0d..7652aab26 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -327,6 +327,9 @@ PICFLAG-$(UCLIBC_FORMAT_DSBT_ELF) := -mdsbt -fpic
PICFLAG := $(PICFLAG-y)
PIEFLAG_NAME:=-fPIE
+$(eval $(call check-gcc-var,-fdata-sections))
+$(eval $(call check-gcc-var,-ffunction-sections))
+
# Some nice CPU specific optimizations
ifeq ($(TARGET_ARCH),i386)
$(eval $(call check-gcc-var,-fomit-frame-pointer))
@@ -630,9 +633,6 @@ LDFLAGS_NOSTRIP:=$(LDFLAG-fuse-ld) $(CPU_LDFLAGS-y) -shared \
#$(eval $(call check-ld-var,--gc-sections))
#LDFLAGS_NOSTRIP += $(LDFLAG_--gc-sections)
-$(eval $(call check-gcc-var,-fdata-sections))
-$(eval $(call check-gcc-var,-ffunction-sections))
-
ifeq ($(UCLIBC_BUILD_RELRO),y)
LDFLAGS_NOSTRIP+=-Wl,-z,relro
endif