aboutsummaryrefslogtreecommitdiffstats
path: root/cc/gen.go
diff options
context:
space:
mode:
authorDan Willemsen <dwillemsen@google.com>2016-11-03 14:28:31 -0700
committerDan Willemsen <dwillemsen@google.com>2016-11-03 14:35:12 -0700
commit9f3c574a3997cafa132694443abdb554341e415f (patch)
tree5b6ae9704af0a2dd49f876559c72c212b608ffa2 /cc/gen.go
parentd8f2014d3bba76a928c0aaa933d85c8ddd43a6da (diff)
downloadbuild_soong-9f3c574a3997cafa132694443abdb554341e415f.tar.gz
build_soong-9f3c574a3997cafa132694443abdb554341e415f.tar.bz2
build_soong-9f3c574a3997cafa132694443abdb554341e415f.zip
Add support for Implicit Outputs
Test: mmma -j system/tools/hidl Test: Inspect out/soong/build.ninja before/after Change-Id: I8e91a033342a12302d51358c5be244e32ad689d7
Diffstat (limited to 'cc/gen.go')
-rw-r--r--cc/gen.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/cc/gen.go b/cc/gen.go
index 9d3a67cf..1000bf81 100644
--- a/cc/gen.go
+++ b/cc/gen.go
@@ -33,11 +33,11 @@ func init() {
var (
yacc = pctx.AndroidStaticRule("yacc",
blueprint.RuleParams{
- Command: "BISON_PKGDATADIR=$yaccDataDir $yaccCmd -d $yaccFlags --defines=$hFile -o $cFile $in",
+ Command: "BISON_PKGDATADIR=$yaccDataDir $yaccCmd -d $yaccFlags --defines=$hFile -o $out $in",
CommandDeps: []string{"$yaccCmd"},
Description: "yacc $out",
},
- "yaccFlags", "cFile", "hFile")
+ "yaccFlags", "hFile")
lex = pctx.AndroidStaticRule("lex",
blueprint.RuleParams{
@@ -51,12 +51,12 @@ func genYacc(ctx android.ModuleContext, yaccFile android.Path, outFile android.M
headerFile = android.GenPathWithExt(ctx, "yacc", yaccFile, "h")
ctx.ModuleBuild(pctx, android.ModuleBuildParams{
- Rule: yacc,
- Outputs: android.WritablePaths{outFile, headerFile},
- Input: yaccFile,
+ Rule: yacc,
+ Output: outFile,
+ ImplicitOutput: headerFile,
+ Input: yaccFile,
Args: map[string]string{
"yaccFlags": yaccFlags,
- "cFile": outFile.String(),
"hFile": headerFile.String(),
},
})