Convert java.Dependency to JavaInfo provider
Export information about java dependencies through a Provider instead of accessing the module directly. Test: java_test.go Test: no changes to build.ninja Change-Id: Ifc5d566bf6f6ebc0ad399e948effaa1ef6a22876
This commit is contained in:
@@ -566,10 +566,11 @@ func createFrameworkAidl(stubsModules []string, path android.OutputPath, ctx and
|
||||
|
||||
ctx.VisitAllModules(func(module android.Module) {
|
||||
// Collect dex jar paths for the modules listed above.
|
||||
if j, ok := module.(Dependency); ok {
|
||||
if ctx.ModuleHasProvider(module, JavaInfoProvider) {
|
||||
j := ctx.ModuleProvider(module, JavaInfoProvider).(JavaInfo)
|
||||
name := ctx.ModuleName(module)
|
||||
if i := android.IndexList(name, stubsModules); i != -1 {
|
||||
stubsJars[i] = j.HeaderJars()
|
||||
stubsJars[i] = j.HeaderJars
|
||||
}
|
||||
}
|
||||
})
|
||||
|
Reference in New Issue
Block a user