Move global cppflags to the beginning of cppflags
Global cppflags should come first so they can be overriden by module cppflags. Test: m -j checkbuild Change-Id: I3454370a6b35f37982b1e0de2e0ec52b54974a8a
This commit is contained in:
parent
5ed99c6472
commit
b668826a85
|
@ -245,17 +245,17 @@ func (compiler *baseCompiler) compilerFlags(ctx ModuleContext, flags Flags) Flag
|
|||
|
||||
if !ctx.noDefaultCompilerFlags() {
|
||||
flags.GlobalFlags = append(flags.GlobalFlags, instructionSetFlags)
|
||||
flags.ConlyFlags = append(flags.ConlyFlags, "${config.CommonGlobalConlyflags}")
|
||||
flags.ConlyFlags = append([]string{"${config.CommonGlobalConlyflags}"}, flags.ConlyFlags...)
|
||||
|
||||
if flags.Clang {
|
||||
flags.AsFlags = append(flags.AsFlags, tc.ClangAsflags())
|
||||
flags.CppFlags = append(flags.CppFlags, "${config.CommonClangGlobalCppflags}")
|
||||
flags.CppFlags = append([]string{"${config.CommonClangGlobalCppflags}"}, flags.CppFlags...)
|
||||
flags.GlobalFlags = append(flags.GlobalFlags,
|
||||
tc.ClangCflags(),
|
||||
"${config.CommonClangGlobalCflags}",
|
||||
fmt.Sprintf("${config.%sClangGlobalCflags}", hod))
|
||||
} else {
|
||||
flags.CppFlags = append(flags.CppFlags, "${config.CommonGlobalCppflags}")
|
||||
flags.CppFlags = append([]string{"${config.CommonGlobalCppflags}"}, flags.CppFlags...)
|
||||
flags.GlobalFlags = append(flags.GlobalFlags,
|
||||
tc.Cflags(),
|
||||
"${config.CommonGlobalCflags}",
|
||||
|
|
Loading…
Reference in New Issue