summaryrefslogtreecommitdiff
path: root/java/java.go
diff options
context:
space:
mode:
author Nicolas Geoffray <ngeoffray@google.com> 2019-01-15 11:48:08 +0000
committer Nicolas Geoffray <ngeoffray@google.com> 2019-01-21 14:02:17 +0000
commit4bdea39ad2fb3cf3ba26a931fa6e81a29c9257d4 (patch)
treebc6970e82edf3302589f8185c909b43014d51a2f /java/java.go
parent1eb88bb4944d9e7d0bd12fb073d6054133d896de (diff)
Don't install java libraries that are already in an apex.
This need to have -hostdex rules not look at the installFile. In the near future, all -hostdex files come from jars that are in an apex. bug: 119868597 Test: m Change-Id: I4423626c5ced5d098ddd97c122fbfced54f817fc
Diffstat (limited to 'java/java.go')
-rw-r--r--java/java.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/java/java.go b/java/java.go
index 9c4bd869e..7e82c59d6 100644
--- a/java/java.go
+++ b/java/java.go
@@ -1395,7 +1395,7 @@ func (j *Library) GenerateAndroidBuildActions(ctx android.ModuleContext) {
j.deviceProperties.UncompressDex = j.shouldUncompressDex(ctx)
j.compile(ctx)
- if Bool(j.properties.Installable) || ctx.Host() {
+ if (Bool(j.properties.Installable) || ctx.Host()) && !android.DirectlyInAnyApex(ctx, ctx.ModuleName()) {
if j.deviceProperties.UncompressDex {
alignedOutputFile := android.PathForModuleOut(ctx, "aligned", ctx.ModuleName()+".jar")
TransformZipAlign(ctx, alignedOutputFile, j.outputFile)