arc: clean-up and move CFLAGS to include/target.mk
authorFelix Fietkau <nbd@openwrt.org>
Mon, 18 Jan 2016 17:52:03 +0000 (17:52 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Mon, 18 Jan 2016 17:52:03 +0000 (17:52 +0000)
Most of currently mentioned CFLAGS in arc770/Makefile
are not really required because:
 [1] "-Os -pipe" are set by default in include/target.mk
 [2] "-fno-caller-saves" gets enabled via menuconfig
     as an extra compiler flag for developers

So the only one that makes sense is "-matomic" and
that one is really essential. Without it many software
packges won't build complainin on unresolved atomic ops.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Felix Fietkau <nbd@openwrt.org>
Cc: Jo-Philipp Wich <jow@openwrt.org>
Cc: Jonas Gorski <jogo@openwrt.org>
SVN-Revision: 48326

include/target.mk
target/linux/arc770/Makefile

index f1292987f22d3f289ba7cfa37d5650f943425c93..d8c0212cf8f4734ef697924e059c39098173a6d9 100644 (file)
@@ -263,6 +263,7 @@ ifeq ($(DUMP),1)
   endif
   ifeq ($(ARCH),arc)
     CPU_TYPE ?= arc700
+    CPU_CFLAGS += -matomic
     CPU_CFLAGS_arc700 = -marc700
   endif
   DEFAULT_CFLAGS=$(strip $(CPU_CFLAGS) $(CPU_CFLAGS_$(CPU_TYPE)) $(CPU_CFLAGS_$(CPU_SUBTYPE)))
index 52c5e0008de2e3f2e867d82228dd95750d9cdc27..f917338aa489ec05eda33e5a169c1e4e2e9ca63a 100644 (file)
@@ -9,7 +9,6 @@ include $(TOPDIR)/rules.mk
 ARCH:=arc
 BOARD:=arc770
 BOARDNAME:=Synopsys DesignWare ARC 770D
-CFLAGS:=-Os -pipe -fno-caller-saves -matomic
 MAINTAINER:=Alexey Brodkin <abrodkin@synopsys.com>
 SUBTARGETS:=generic