Use Rule-local implicit dependencies

Depends on https://github.com/google/blueprint/pull/78

This uses the new CommandDeps field to move implicit dependencies
embedded in the Command string next to the definition, instead of having
to specify them in every BuildParam struct. This should make it easier
to verify dependencies.

Change-Id: I2711b160920e22fa962a436e1f7041272166f50f
diff --git a/cc/gen.go b/cc/gen.go
index 3bfe679..be50d75 100644
--- a/cc/gen.go
+++ b/cc/gen.go
@@ -38,6 +38,7 @@
 		blueprint.RuleParams{
 			Command: "BISON_PKGDATADIR=$yaccDataDir $yaccCmd -d $yaccFlags -o $cppFile $in && " +
 				"cp -f $hppFile $hFile",
+			CommandDeps: []string{"$yaccCmd"},
 			Description: "yacc $out",
 		},
 		"yaccFlags", "cppFile", "hppFile", "hFile")
@@ -45,6 +46,7 @@
 	lex = pctx.StaticRule("lex",
 		blueprint.RuleParams{
 			Command:     "$lexCmd -o$out $in",
+			CommandDeps: []string{"$lexCmd"},
 			Description: "lex $out",
 		})
 )
@@ -57,10 +59,9 @@
 	headerFile = pathtools.ReplaceExtension(cppFile, "h")
 
 	ctx.Build(pctx, blueprint.BuildParams{
-		Rule:      yacc,
-		Outputs:   []string{cppFile, headerFile},
-		Inputs:    []string{yaccFile},
-		Implicits: []string{"$yaccCmd"},
+		Rule:    yacc,
+		Outputs: []string{cppFile, headerFile},
+		Inputs:  []string{yaccFile},
 		Args: map[string]string{
 			"yaccFlags": yaccFlags,
 			"cppFile":   cppFile,
@@ -78,10 +79,9 @@
 	cppFile = pathtools.ReplaceExtension(cppFile, "cpp")
 
 	ctx.Build(pctx, blueprint.BuildParams{
-		Rule:      lex,
-		Outputs:   []string{cppFile},
-		Inputs:    []string{lexFile},
-		Implicits: []string{"$lexCmd"},
+		Rule:    lex,
+		Outputs: []string{cppFile},
+		Inputs:  []string{lexFile},
 	})
 
 	return cppFile