Fix aapt2

Fix some ninja variable issues in the aapt2 rules.  These were
caught by app_test.go, but that wasn't being run automatically,
so add it to testSrcs.

Test: app_test.go
Change-Id: Ia01dda45ba5ced9c304056939c0e69f170c15de3
This commit is contained in:
Colin Cross 2017-11-29 00:17:36 -08:00
parent a8063afc16
commit 44f066895d
2 changed files with 4 additions and 3 deletions

View file

@ -224,6 +224,7 @@ bootstrap_go_package {
"java/system_modules.go",
],
testSrcs: [
"java/app_test.go",
"java/java_test.go",
],
pluginFor: ["soong_build"],

View file

@ -54,7 +54,7 @@ func pathsToAapt2Paths(ctx android.ModuleContext, resPaths android.Paths) androi
var aapt2CompileRule = pctx.AndroidStaticRule("aapt2Compile",
blueprint.RuleParams{
Command: `${config.Aapt2Cmd compile -o $outDir $cFlags --legacy $in`,
Command: `${config.Aapt2Cmd} compile -o $outDir $cFlags --legacy $in`,
CommandDeps: []string{"${config.Aapt2Cmd}"},
},
"outDir", "cFlags")
@ -90,10 +90,10 @@ func aapt2Compile(ctx android.ModuleContext, dir android.Path, paths android.Pat
var aapt2LinkRule = pctx.AndroidStaticRule("aapt2Link",
blueprint.RuleParams{
Command: `$aapt2Cmd link -o $out $flags --java $genDir --proguard $proguardOptions $inFlags && ` +
Command: `${config.Aapt2Cmd} link -o $out $flags --java $genDir --proguard $proguardOptions $inFlags && ` +
`${config.SoongZipCmd} -write_if_changed -jar -o $genJar -C $genDir -D $genDir`,
CommandDeps: []string{
"$aapt2Cmd",
"${config.Aapt2Cmd}",
"${config.SoongZipCmd}",
},
Restat: true,