summaryrefslogtreecommitdiff
path: root/build/art.go
diff options
context:
space:
mode:
author David Srbecky <dsrbecky@google.com> 2020-06-25 15:23:15 +0100
committer David Srbecky <dsrbecky@google.com> 2020-06-26 17:14:57 +0000
commit22872da653053bb4b86fbef67163a9f6b7aee25b (patch)
tree5355ac349eeb15165c6db0c17e93f1286c52a3d4 /build/art.go
parent11303f2983bf2ef8d55870afcd0d5937f0778753 (diff)
Support running of host gtests in eng-prod
Add more libraries and tools to the shared ART directory in testcases. Change the tests environment setup, so that it can find the tools. Vast majority of tests pass. Some individual tests still need fixing. Bug: 147817558 Test: run gtests in forrest Change-Id: I3214f532436828c2a1a5a543e69d6b9bcf1e42af
Diffstat (limited to 'build/art.go')
-rw-r--r--build/art.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/build/art.go b/build/art.go
index 8deea23098..af2a5deb54 100644
--- a/build/art.go
+++ b/build/art.go
@@ -291,10 +291,11 @@ func addTestcasesFile(ctx android.InstallHookContext) {
defer artTestMutex.Unlock()
if ctx.Os().Class == android.Host {
- path := ctx.Path().ToMakePath().String()
- parts := strings.Split(path, "/")
- // Keep last two parts of the path (e.g. bin/dex2oat).
- testcasesContent[strings.Join(parts[len(parts)-2:], "/")] = path
+ src := ctx.SrcPath().String()
+ path := strings.Split(ctx.Path().ToMakePath().String(), "/")
+ // Keep last two parts of the install path (e.g. bin/dex2oat).
+ dst := strings.Join(path[len(path)-2:], "/")
+ testcasesContent[dst] = src
}
}