diff options
Diffstat (limited to 'java/base.go')
-rw-r--r-- | java/base.go | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/java/base.go b/java/base.go index c0da21523..c45ef641e 100644 --- a/java/base.go +++ b/java/base.go @@ -372,6 +372,7 @@ type Module struct { android.DefaultableModuleBase android.ApexModuleBase android.SdkBase + android.BazelModuleBase // Functionality common to Module and Import. embeddableInModuleAndImport @@ -1952,3 +1953,17 @@ type ModuleWithStem interface { } var _ ModuleWithStem = (*Module)(nil) + +func (j *Module) ConvertWithBp2build(ctx android.TopDownMutatorContext) { + switch ctx.ModuleType() { + case "java_library", "java_library_host": + if lib, ok := ctx.Module().(*Library); ok { + javaLibraryBp2Build(ctx, lib) + } + case "java_binary_host": + if binary, ok := ctx.Module().(*Binary); ok { + javaBinaryHostBp2Build(ctx, binary) + } + } + +} |