Split CommonGlobalIncludes for system includes

am: 1cfd89aca3

Change-Id: If983beb6b00b0e6348f838ad2a44616a4711cd63
This commit is contained in:
Colin Cross 2016-09-15 18:17:50 +00:00 committed by android-build-merger
commit 74a8c40cca
3 changed files with 6 additions and 3 deletions

View File

@ -147,6 +147,7 @@ func (compiler *baseCompiler) compilerFlags(ctx ModuleContext, flags Flags) Flag
if !ctx.sdk() || ctx.Host() {
flags.GlobalFlags = append(flags.GlobalFlags,
"${config.CommonGlobalIncludes}",
"${config.CommonGlobalSystemIncludes}",
tc.IncludeFlags(),
"${config.CommonNativehelperInclude}")
}

View File

@ -90,9 +90,11 @@ func init() {
pctx.StaticVariable("CommonClangGlobalCppflags",
strings.Join(append(ClangFilterUnknownCflags(commonGlobalCppflags), "${ClangExtraCppflags}"), " "))
// Everything in this list is a crime against abstraction and dependency tracking.
// Everything in these lists is a crime against abstraction and dependency tracking.
// Do not add anything to this list.
pctx.PrefixedPathsForOptionalSourceVariable("CommonGlobalIncludes", "-isystem ",
pctx.PrefixedPathsForOptionalSourceVariable("CommonGlobalIncludes", "-I",
[]string{})
pctx.PrefixedPathsForOptionalSourceVariable("CommonGlobalSystemIncludes", "-isystem ",
[]string{
"system/core/include",
"system/media/audio/include",

View File

@ -44,7 +44,7 @@ func makeVarsProvider(ctx android.MakeVarsContext) {
ctx.Strict("GLOBAL_CLANG_CPPFLAGS_NO_OVERRIDE", "")
ctx.Strict("NDK_PREBUILT_SHARED_LIBRARIES", strings.Join(ndkPrebuiltSharedLibs, " "))
includeFlags, err := ctx.Eval("${config.CommonGlobalIncludes}")
includeFlags, err := ctx.Eval("${config.CommonGlobalIncludes} ${config.CommonGlobalSystemIncludes}")
if err != nil {
panic(err)
}