OSDN Git Service

definitions.mk: Don't use GCC '@' parameter
authorAndrew Boie <andrew.p.boie@intel.com>
Wed, 11 Jul 2012 19:14:56 +0000 (12:14 -0700)
committerAndrew Boie <andrew.p.boie@intel.com>
Thu, 26 Jul 2012 17:21:04 +0000 (10:21 -0700)
This parameter (which causes GCC to pull additional command line
parameters out of a file) is incompatible with ccache.

- With ccache 2.x, ccache will ignore this parameters, and potentially
compute invalid command line hashes since it is not reading the
parameter file

- With ccache 3.x, ccache will refuse to cache the files and error
with 'Unsupported compiler option'.

We still use the parameter file, but Make expands it instead.

Change-Id: I070c3877cbe2d058e1cf4754bac535e7f3498861
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
core/definitions.mk

index 9fe0a11..c1757f3 100644 (file)
@@ -883,7 +883,7 @@ define transform-cpp-to-o
 @echo "target $(PRIVATE_ARM_MODE) C++: $(PRIVATE_MODULE) <= $<"
 $(hide) $(PRIVATE_CXX) \
        $(addprefix -I , $(PRIVATE_C_INCLUDES)) \
-       @$(PRIVATE_IMPORT_INCLUDES) \
+       $(shell cat $(PRIVATE_IMPORT_INCLUDES)) \
        $(addprefix -isystem ,\
            $(if $(PRIVATE_NO_DEFAULT_COMPILER_FLAGS),, \
                $(filter-out $(PRIVATE_C_INCLUDES), \
@@ -913,7 +913,7 @@ define transform-c-or-s-to-o-no-deps
 @mkdir -p $(dir $@)
 $(hide) $(PRIVATE_CC) \
        $(addprefix -I , $(PRIVATE_C_INCLUDES)) \
-       @$(PRIVATE_IMPORT_INCLUDES) \
+       $(shell cat $(PRIVATE_IMPORT_INCLUDES)) \
        $(addprefix -isystem ,\
            $(if $(PRIVATE_NO_DEFAULT_COMPILER_FLAGS),, \
                $(filter-out $(PRIVATE_C_INCLUDES), \
@@ -975,7 +975,7 @@ define transform-host-cpp-to-o
 @echo "host C++: $(PRIVATE_MODULE) <= $<"
 $(hide) $(PRIVATE_CXX) \
        $(addprefix -I , $(PRIVATE_C_INCLUDES)) \
-       @$(PRIVATE_IMPORT_INCLUDES) \
+       $(shell cat $(PRIVATE_IMPORT_INCLUDES)) \
        $(addprefix -isystem ,\
            $(if $(PRIVATE_NO_DEFAULT_COMPILER_FLAGS),, \
                $(filter-out $(PRIVATE_C_INCLUDES), \
@@ -1003,7 +1003,7 @@ define transform-host-c-or-s-to-o-no-deps
 @mkdir -p $(dir $@)
 $(hide) $(PRIVATE_CC) \
        $(addprefix -I , $(PRIVATE_C_INCLUDES)) \
-       @$(PRIVATE_IMPORT_INCLUDES) \
+       $(shell cat $(PRIVATE_IMPORT_INCLUDES)) \
        $(addprefix -isystem ,\
            $(if $(PRIVATE_NO_DEFAULT_COMPILER_FLAGS),, \
                $(filter-out $(PRIVATE_C_INCLUDES), \