diff options
| author | 2020-03-16 13:27:55 +0000 | |
|---|---|---|
| committer | 2020-03-17 11:00:46 +0000 | |
| commit | 46672321e426d96b4ddee1a6386ec7bbaeb03d5c (patch) | |
| tree | 9a361adc0ffb9797803bcf8f82dcb7bf3ac6a409 | |
| parent | 8fed7d4057dd3c334f9dd45b0f06a763c241541e (diff) | |
Rename ART dump-oat rules.
Follow-up to CL/1235086 which renamed the rules.
Preserve the name for target since ART tests depends on it.
Test: m dump-oat-boot-x86
Change-Id: I67c7ea9e99fea24f089d38856811bfa320258b54
| -rw-r--r-- | java/dexpreopt_bootjars.go | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/java/dexpreopt_bootjars.go b/java/dexpreopt_bootjars.go index 7ccf82828..8e621c713 100644 --- a/java/dexpreopt_bootjars.go +++ b/java/dexpreopt_bootjars.go @@ -547,7 +547,11 @@ func dumpOatRules(ctx android.SingletonContext, image *bootImageConfig) { var allPhonies android.Paths for _, image := range image.variants { arch := image.target.Arch.ArchType - suffix := image.target.String() + suffix := arch.String() + // Host and target might both use x86 arch. We need to ensure the names are unique. + if image.target.Os.Class == android.Host { + suffix = "host-" + suffix + } // Create a rule to call oatdump. output := android.PathForOutput(ctx, "boot."+suffix+".oatdump.txt") rule := android.NewRuleBuilder() @@ -570,7 +574,10 @@ func dumpOatRules(ctx android.SingletonContext, image *bootImageConfig) { Text("echo").FlagWithArg("Output in ", output.String()) rule.Build(pctx, ctx, "phony-dump-oat-boot-"+suffix, "dump oat boot "+arch.String()) - allPhonies = append(allPhonies, phony) + // TODO: We need to make imageLocations per-variant to make oatdump work on host. + if image.target.Os == android.Android { + allPhonies = append(allPhonies, phony) + } } phony := android.PathForPhony(ctx, "dump-oat-boot") |