Skip to content

Commit 9a39e27

Browse files
author
Sam Ravnborg
committed
kbuild: fix up CFLAGS usage
Only in very rare cases is it needed to change CFLAGS outside of arch/*/Makefile. Fix up all wrong cases - in most cases the use of EXTRA_CFLAGS is the only thing needed. Signed-off-by: Sam Ravnborg <[email protected]>
1 parent e004982 commit 9a39e27

File tree

4 files changed

+4
-7
lines changed

4 files changed

+4
-7
lines changed

arch/parisc/math-emu/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#
44

55
# See arch/parisc/math-emu/README
6-
CFLAGS += -Wno-parentheses -Wno-implicit-function-declaration \
6+
EXTRA_CFLAGS += -Wno-parentheses -Wno-implicit-function-declaration \
77
-Wno-uninitialized -Wno-strict-prototypes -Wno-return-type \
88
-Wno-implicit-int
99

arch/ppc/boot/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
# modified by Cort ([email protected])
1414
#
1515

16-
CFLAGS += -fno-builtin -D__BOOTER__ -Iarch/$(ARCH)/boot/include
1716
HOSTCFLAGS += -Iarch/$(ARCH)/boot/include
1817

1918
BOOT_TARGETS = zImage zImage.initrd znetboot znetboot.initrd

arch/x86/math-emu/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
#DEBUG = -DDEBUGGING
66
DEBUG =
77
PARANOID = -DPARANOID
8-
CFLAGS := $(CFLAGS) $(PARANOID) $(DEBUG) -fno-builtin $(MATH_EMULATION)
9-
8+
EXTRA_CFLAGS := $(PARANOID) $(DEBUG) -fno-builtin $(MATH_EMULATION)
109
EXTRA_AFLAGS := $(PARANOID)
1110

1211
# From 'C' language sources:

arch/xtensa/boot/Makefile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,12 @@
88
#
99

1010

11-
CFLAGS += -fno-builtin -Iarch/$(ARCH)/boot/include
11+
EXTRA_CFLAGS += -fno-builtin -Iarch/$(ARCH)/boot/include
1212
HOSTFLAGS += -Iarch/$(ARCH)/boot/include
1313

1414
BIG_ENDIAN := $(shell echo -e __XTENSA_EB__ | $(CC) -E - | grep -v "\#")
1515

16-
export CFLAGS
17-
export AFLAGS
16+
export EXTRA_CFLAGS
1817
export BIG_ENDIAN
1918

2019
subdir-y := lib

0 commit comments

Comments
 (0)