Remove ConvertWithBp2build implementations
Remove the ConvertWithBp2build implementations from all the module types, along with the related code. Bug: 315353489 Test: m blueprint_tests Change-Id: I212672286686a318893bc7348ddd5a5ec51e77a7
This commit is contained in:
@@ -16,7 +16,6 @@ package java
|
||||
|
||||
import (
|
||||
"android/soong/android"
|
||||
"android/soong/bazel"
|
||||
)
|
||||
|
||||
func init() {
|
||||
@@ -35,8 +34,6 @@ func PluginFactory() android.Module {
|
||||
|
||||
InitJavaModule(module, android.HostSupported)
|
||||
|
||||
android.InitBazelModule(module)
|
||||
|
||||
return module
|
||||
}
|
||||
|
||||
@@ -56,38 +53,3 @@ type PluginProperties struct {
|
||||
// parallelism and cause more recompilation for modules that depend on modules that use this plugin.
|
||||
Generates_api *bool
|
||||
}
|
||||
|
||||
type pluginAttributes struct {
|
||||
*javaCommonAttributes
|
||||
Deps bazel.LabelListAttribute
|
||||
Processor_class *string
|
||||
}
|
||||
|
||||
// ConvertWithBp2build is used to convert android_app to Bazel.
|
||||
func (p *Plugin) ConvertWithBp2build(ctx android.Bp2buildMutatorContext) {
|
||||
pluginName := p.Name()
|
||||
commonAttrs, bp2BuildInfo, supported := p.convertLibraryAttrsBp2Build(ctx)
|
||||
if !supported {
|
||||
return
|
||||
}
|
||||
depLabels := bp2BuildInfo.DepLabels
|
||||
|
||||
deps := depLabels.Deps
|
||||
deps.Append(depLabels.StaticDeps)
|
||||
|
||||
var processorClass *string
|
||||
if p.pluginProperties.Processor_class != nil {
|
||||
processorClass = p.pluginProperties.Processor_class
|
||||
}
|
||||
|
||||
attrs := &pluginAttributes{
|
||||
javaCommonAttributes: commonAttrs,
|
||||
Deps: deps,
|
||||
Processor_class: processorClass,
|
||||
}
|
||||
|
||||
props := bazel.BazelTargetModuleProperties{
|
||||
Rule_class: "java_plugin",
|
||||
}
|
||||
ctx.CreateBazelTargetModule(props, android.CommonAttributes{Name: pluginName}, attrs)
|
||||
}
|
||||
|
Reference in New Issue
Block a user