summaryrefslogtreecommitdiff
path: root/java/bootclasspath_fragment.go
diff options
context:
space:
mode:
Diffstat (limited to 'java/bootclasspath_fragment.go')
-rw-r--r--java/bootclasspath_fragment.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/java/bootclasspath_fragment.go b/java/bootclasspath_fragment.go
index d7525ecce..8fe362a56 100644
--- a/java/bootclasspath_fragment.go
+++ b/java/bootclasspath_fragment.go
@@ -145,11 +145,6 @@ func bootclasspathFragmentInitContentsFromImage(ctx android.EarlyModuleContext,
ctx.ModuleErrorf(`neither of the "image_name" and "contents" properties have been supplied, please supply exactly one`)
}
- if len(contents) != 0 {
- // Nothing to do.
- return
- }
-
imageName := proptools.String(m.properties.Image_name)
if imageName == "art" {
// TODO(b/177892522): Prebuilts (versioned or not) should not use the image_name property.
@@ -181,7 +176,7 @@ func bootclasspathFragmentInitContentsFromImage(ctx android.EarlyModuleContext,
continue
}
if !m.AvailableFor(apex) {
- ctx.ModuleErrorf("incompatible with ArtApexJars which expects this to be in apex %q but this is only in apexes %q",
+ ctx.ModuleErrorf("ArtApexJars configuration incompatible with this module, ArtApexJars expects this to be in apex %q but this is only in apexes %q",
apex, m.ApexAvailable())
continue
}
@@ -193,6 +188,11 @@ func bootclasspathFragmentInitContentsFromImage(ctx android.EarlyModuleContext,
}
}
+ if len(contents) != 0 {
+ // Nothing to do.
+ return
+ }
+
// Store the jars in the Contents property so that they can be used to add dependencies.
m.properties.Contents = modules.CopyOfJars()
}