From ff60a73d899d2d0d1c23eca503a2aeb3fdbd1feb Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Thu, 13 Jun 2019 16:52:01 +0000 Subject: Depend on all the files from system modules Instead of just one of the files that we pass into javac. Test: treehugger Change-Id: I8478e88656487c9f667893d7c17839f0ea63c78f --- java/java.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'java/java.go') diff --git a/java/java.go b/java/java.go index 4b3845161..a2e9ab023 100644 --- a/java/java.go +++ b/java/java.go @@ -628,6 +628,7 @@ type deps struct { srcs android.Paths srcJars android.Paths systemModules android.Path + systemModulesDeps android.Paths aidlPreprocess android.OptionalPath kotlinStdlib android.Paths kotlinAnnotations android.Paths @@ -835,10 +836,11 @@ func (j *Module) collectDeps(ctx android.ModuleContext) deps { panic("Found two system module dependencies") } sm := module.(*SystemModules) - if sm.outputFile == nil { + if sm.outputDir == nil || len(sm.outputDeps) == 0 { panic("Missing directory for system module dependency") } - deps.systemModules = sm.outputFile + deps.systemModules = sm.outputDir + deps.systemModulesDeps = sm.outputDeps } } }) @@ -968,6 +970,7 @@ func (j *Module) collectBuilderFlags(ctx android.ModuleContext, deps deps) javaB // systemModules if deps.systemModules != nil { flags.systemModules = append(flags.systemModules, deps.systemModules) + flags.systemModulesDeps = append(flags.systemModulesDeps, deps.systemModulesDeps...) } // aidl flags. -- cgit v1.2.3-59-g8ed1b