summaryrefslogtreecommitdiff
path: root/java/java.go
diff options
context:
space:
mode:
authorUlyana Trafimovich <skvadrik@google.com>2020-09-10 14:34:20 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2020-09-10 14:34:20 +0000
commit79a94a27b67d99324bf176e579ddfd74d8a28f7e (patch)
tree0620195828f02d63b889a96e835d2e528a4ccfb6 /java/java.go
parent3e0b9c031caa7f004330d780d9d4631df3ee4bb3 (diff)
parent54027b572e49c8d17cc686d241878d70c517b969 (diff)
Merge "Replace `is_uses_lib` property with `provides_uses_lib`."
Diffstat (limited to 'java/java.go')
-rw-r--r--java/java.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/java/java.go b/java/java.go
index eb8841732..f0d3aaf3b 100644
--- a/java/java.go
+++ b/java/java.go
@@ -1979,9 +1979,9 @@ func (j *Library) GenerateAndroidBuildActions(ctx android.ModuleContext) {
// added to the Android manifest.
j.exportedSdkLibs.MaybeAddLibraryPath(ctx, j.OptionalImplicitSdkLibrary(), j.DexJarBuildPath(), j.DexJarInstallPath())
- // If this is a non-SDK uses-library, export itself.
- if proptools.Bool(j.usesLibraryProperties.Is_uses_lib) {
- j.exportedSdkLibs.AddLibraryPath(ctx, ctx.ModuleName(), j.DexJarBuildPath(), j.DexJarInstallPath())
+ // A non-SDK library may provide a <uses-library> (the name may be different from the module name).
+ if lib := proptools.String(j.usesLibraryProperties.Provides_uses_lib); lib != "" {
+ j.exportedSdkLibs.AddLibraryPath(ctx, lib, j.DexJarBuildPath(), j.DexJarInstallPath())
}
j.distFiles = j.GenerateTaggedDistFiles(ctx)