Create dexpreopt install dir

If dexpreopt is disabled inside dexpreopt_gen there won't be any installed files and the install directory won't be created, causing soong_zip to fail.  Create the directory ahead of time.

Test: treehugger
Change-Id: Icf17d0bcd617eeeafdcd50ab56359fa8d6612822
This commit is contained in:
Colin Cross 2018-12-19 18:31:34 +00:00
parent 3a0989ce4c
commit ed91ae94e2

View file

@ -104,6 +104,7 @@ func writeScripts(global dexpreopt.GlobalConfig, module dexpreopt.ModuleConfig,
installDir := filepath.Join(filepath.Dir(module.BuildPath), "dexpreopt_install") installDir := filepath.Join(filepath.Dir(module.BuildPath), "dexpreopt_install")
dexpreoptRule.Command().FlagWithArg("rm -rf ", installDir) dexpreoptRule.Command().FlagWithArg("rm -rf ", installDir)
dexpreoptRule.Command().FlagWithArg("mkdir -p ", installDir)
for _, install := range dexpreoptRule.Installs() { for _, install := range dexpreoptRule.Installs() {
installPath := filepath.Join(installDir, install.To) installPath := filepath.Join(installDir, install.To)