aboutsummaryrefslogtreecommitdiff
path: root/java/genrule_combiner.go
diff options
context:
space:
mode:
Diffstat (limited to 'java/genrule_combiner.go')
-rw-r--r--java/genrule_combiner.go14
1 files changed, 8 insertions, 6 deletions
diff --git a/java/genrule_combiner.go b/java/genrule_combiner.go
index 357dc2c76..db6af1ad2 100644
--- a/java/genrule_combiner.go
+++ b/java/genrule_combiner.go
@@ -95,7 +95,7 @@ func (j *GenruleCombiner) GenerateAndroidBuildActions(ctx android.ModuleContext)
// Collect the headers first, so that aconfig flag values for the libraries will override
// values from the headers (if they are different).
- ctx.VisitDirectDepsWithTag(genruleCombinerHeaderDepTag, func(m android.Module) {
+ ctx.VisitDirectDepsProxyWithTag(genruleCombinerHeaderDepTag, func(m android.ModuleProxy) {
if dep, ok := android.OtherModuleProvider(ctx, m, JavaInfoProvider); ok {
j.headerJars = append(j.headerJars, dep.HeaderJars...)
@@ -113,7 +113,7 @@ func (j *GenruleCombiner) GenerateAndroidBuildActions(ctx android.ModuleContext)
ctx.PropertyErrorf("headers", "module %q cannot be used as a dependency", ctx.OtherModuleName(m))
}
})
- ctx.VisitDirectDepsWithTag(staticLibTag, func(m android.Module) {
+ ctx.VisitDirectDepsProxyWithTag(staticLibTag, func(m android.ModuleProxy) {
if dep, ok := android.OtherModuleProvider(ctx, m, JavaInfoProvider); ok {
j.implementationJars = append(j.implementationJars, dep.ImplementationJars...)
j.implementationAndResourceJars = append(j.implementationAndResourceJars, dep.ImplementationAndResourcesJars...)
@@ -178,6 +178,12 @@ func (j *GenruleCombiner) GenerateAndroidBuildActions(ctx android.ModuleContext)
ctx.SetOutputFiles(javaInfo.HeaderJars, ".hjar")
android.SetProvider(ctx, JavaInfoProvider, javaInfo)
+ moduleInfoJSON := ctx.ModuleInfoJSON()
+ moduleInfoJSON.Class = []string{"JAVA_LIBRARIES"}
+ if j.combinedImplementationJar != nil {
+ moduleInfoJSON.ClassesJar = []string{j.combinedImplementationJar.String()}
+ }
+ moduleInfoJSON.SystemSharedLibs = []string{"none"}
}
func (j *GenruleCombiner) GeneratedSourceFiles() android.Paths {
@@ -220,10 +226,6 @@ func (j *GenruleCombiner) ClassLoaderContexts() dexpreopt.ClassLoaderContextMap
return nil
}
-func (j *GenruleCombiner) JacocoReportClassesFile() android.Path {
- return nil
-}
-
func (j *GenruleCombiner) AndroidMk() android.AndroidMkData {
return android.AndroidMkData{
Class: "JAVA_LIBRARIES",