kbuild: enable 'make CFLAGS=...' to add additional options to CC
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / arch / sh64 / Makefile
index 8ca57ffa2b709f57cc23453cc1dd0c293a558ffa..9e874de0a0968231e41d13b7aa30c9422ea0ff55 100644 (file)
@@ -26,8 +26,7 @@ LDFLAGS                       += -EB  -mshelf32_linux
 endif
 
 # No requirements for endianess support from AFLAGS, 'as' always run through gcc
-AFLAGS         += -m5 -isa=sh64 -traditional
-CFLAGS         += $(cpu-y)
+KBUILD_CFLAGS          += $(cpu-y)
 
 LDFLAGS_vmlinux        += --defsym phys_stext=_stext-$(CONFIG_CACHED_MEMORY_OFFSET) \
                  --defsym phys_stext_shmedia=phys_stext+1 \
@@ -58,7 +57,7 @@ ifneq ($(machine-y),)
 core-y += arch/sh64/mach-$(machine-y)/
 endif
 
-LIBGCC := $(shell $(CC) $(CFLAGS) -print-libgcc-file-name)
+LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name)
 libs-y += arch/$(ARCH)/lib/ $(LIBGCC)
 
 drivers-$(CONFIG_OPROFILE)     += arch/sh64/oprofile/