summaryrefslogtreecommitdiff
path: root/java/java.go
diff options
context:
space:
mode:
Diffstat (limited to 'java/java.go')
-rw-r--r--java/java.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/java/java.go b/java/java.go
index b4ce35ede..d7b5847d5 100644
--- a/java/java.go
+++ b/java/java.go
@@ -385,11 +385,9 @@ func (j *Module) compile(ctx android.ModuleContext) {
}
resourceJarSpecs := ResourceDirsToJarSpecs(ctx, j.properties.Resource_dirs, j.properties.Exclude_resource_dirs)
- manifest := android.OptionalPathForModuleSrc(ctx, j.properties.Manifest)
-
- if len(resourceJarSpecs) > 0 || manifest.Valid() {
+ if len(resourceJarSpecs) > 0 {
// Combine classes + resources into classes-full-debug.jar
- resourceJar := TransformResourcesToJar(ctx, resourceJarSpecs, manifest, extraJarDeps)
+ resourceJar := TransformResourcesToJar(ctx, resourceJarSpecs, extraJarDeps)
if ctx.Failed() {
return
}
@@ -399,9 +397,11 @@ func (j *Module) compile(ctx android.ModuleContext) {
jars = append(jars, deps.staticJars...)
+ manifest := android.OptionalPathForModuleSrc(ctx, j.properties.Manifest)
+
// Combine the classes built from sources, any manifests, and any static libraries into
// classes-combined.jar. If there is only one input jar this step will be skipped.
- outputFile := TransformJarsToJar(ctx, "classes-combined.jar", jars)
+ outputFile := TransformJarsToJar(ctx, "classes.jar", jars, manifest, false)
if j.properties.Jarjar_rules != nil {
jarjar_rules := android.PathForModuleSrc(ctx, *j.properties.Jarjar_rules)
@@ -616,7 +616,7 @@ func (j *Import) DepsMutator(ctx android.BottomUpMutatorContext) {
func (j *Import) GenerateAndroidBuildActions(ctx android.ModuleContext) {
j.classpathFiles = android.PathsForModuleSrc(ctx, j.properties.Jars)
- j.combinedClasspathFile = TransformJarsToJar(ctx, "classes.jar", j.classpathFiles)
+ j.combinedClasspathFile = TransformJarsToJar(ctx, "classes.jar", j.classpathFiles, android.OptionalPath{}, false)
}
var _ Dependency = (*Import)(nil)