diff --git a/android/rule_builder.go b/android/rule_builder.go index 97582db2c..245b759ca 100644 --- a/android/rule_builder.go +++ b/android/rule_builder.go @@ -756,9 +756,13 @@ func (r *RuleBuilder) build(name string, desc string, ninjaEscapeCommandString b pool = localPool } + if ninjaEscapeCommandString { + commandString = proptools.NinjaEscape(commandString) + } + r.ctx.Build(r.pctx, BuildParams{ Rule: r.ctx.Rule(r.pctx, name, blueprint.RuleParams{ - Command: proptools.NinjaEscape(commandString), + Command: commandString, CommandDeps: proptools.NinjaEscapeList(tools.Strings()), Restat: r.restat, Rspfile: proptools.NinjaEscape(rspFile),