- do not hardcode HOSTCFLAGS to gcc specific flags. Fixes errors when not using gcc...
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Wed, 20 Jun 2007 10:01:12 +0000 (10:01 -0000)
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Wed, 20 Jun 2007 10:01:12 +0000 (10:01 -0000)
Makefile

index 4a87573b7f9e6ce9279e072c002605272e0638bb..afb4663e8c3f7264d31dce053ccad1120d5220d0 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -183,11 +183,6 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
          else if [ -x /bin/bash ]; then echo /bin/bash; \
          else echo sh; fi ; fi)
 
-HOSTCC         = gcc
-HOSTCXX        = g++
-HOSTCFLAGS     = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer
-HOSTCXXFLAGS   = -O2
-
 #      Decide whether to build built-in, modular, or both.
 #      Normally, just do built-in.
 
@@ -262,9 +257,16 @@ export quiet Q KBUILD_VERBOSE
 # Look for make include files relative to root of kernel src
 MAKEFLAGS += --include-dir=$(srctree)
 
+HOSTCC         = gcc
+HOSTCXX        = g++
+HOSTCFLAGS     :=
+HOSTCXXFLAGS   :=
 # We need some generic definitions
 include $(srctree)/scripts/Kbuild.include
 
+HOSTCFLAGS     += $(call hostcc-option,-Wall -Wstrict-prototypes -O2 -fomit-frame-pointer,)
+HOSTCXXFLAGS   += -O2
+
 # For maximum performance (+ possibly random breakage, uncomment
 # the following)