aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Willemsen <dwillemsen@google.com>2016-01-12 16:22:40 -0800
committerDan Willemsen <dwillemsen@google.com>2016-01-13 14:01:42 -0800
commitfc9c28ca02d2e59c03d387ab17eddf974d794fa8 (patch)
tree0759e6e9d3a95c94656a138df4520df0289030e1
parent6dd0660905ee2236aaee8450d583a3b320505b41 (diff)
downloadbuild_soong-fc9c28ca02d2e59c03d387ab17eddf974d794fa8.tar.gz
build_soong-fc9c28ca02d2e59c03d387ab17eddf974d794fa8.tar.bz2
build_soong-fc9c28ca02d2e59c03d387ab17eddf974d794fa8.zip
Toolchain modules use GCC
Don't use clang cflags if the device uses clang by default. Change-Id: Ice8474ae1f5e6f37fc8b47b1679d7fbdb9249e5a
-rw-r--r--cc/cc.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/cc/cc.go b/cc/cc.go
index bc486225..6cff27f8 100644
--- a/cc/cc.go
+++ b/cc/cc.go
@@ -1882,6 +1882,7 @@ func ToolchainLibraryFactory() (blueprint.Module, []interface{}) {
module := &toolchainLibrary{}
module.LibraryProperties.BuildStatic = true
+ module.Properties.Clang = proptools.BoolPtr(false)
return newCCBase(&module.CCBase, module, common.DeviceSupported, common.MultilibBoth,
&module.LibraryProperties)
@@ -1893,6 +1894,10 @@ func (c *toolchainLibrary) compileModule(ctx common.AndroidModuleContext,
libName := ctx.ModuleName() + staticLibraryExtension
outputFile := common.PathForModuleOut(ctx, libName)
+ if flags.Clang {
+ ctx.ModuleErrorf("toolchain_library must use GCC, not Clang")
+ }
+
CopyGccLib(ctx, libName, ccFlagsToBuilderFlags(flags), outputFile)
c.out = outputFile