From ed91ae94e226f88349bdf5aba0389d8d761ac291 Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Wed, 19 Dec 2018 18:31:34 +0000 Subject: [PATCH] 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 --- dexpreopt/dexpreopt_gen/dexpreopt_gen.go | 1 + 1 file changed, 1 insertion(+) diff --git a/dexpreopt/dexpreopt_gen/dexpreopt_gen.go b/dexpreopt/dexpreopt_gen/dexpreopt_gen.go index c010056ab..46d8795a8 100644 --- a/dexpreopt/dexpreopt_gen/dexpreopt_gen.go +++ b/dexpreopt/dexpreopt_gen/dexpreopt_gen.go @@ -104,6 +104,7 @@ func writeScripts(global dexpreopt.GlobalConfig, module dexpreopt.ModuleConfig, installDir := filepath.Join(filepath.Dir(module.BuildPath), "dexpreopt_install") dexpreoptRule.Command().FlagWithArg("rm -rf ", installDir) + dexpreoptRule.Command().FlagWithArg("mkdir -p ", installDir) for _, install := range dexpreoptRule.Installs() { installPath := filepath.Join(installDir, install.To)