Getting rid of old hacky Libs conversion
Now that libs conversion is happening for the needed module_types, removing if statement with old hacky libs conversion Test: Presubmit Bug: 244210934 Change-Id: I92bb2080eeb7dcb85d087a3ff6054bdf8675ec54
This commit is contained in:
15
java/java.go
15
java/java.go
@@ -2675,17 +2675,10 @@ func (m *Library) convertLibraryAttrsBp2Build(ctx android.TopDownMutatorContext)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if m.properties.Libs != nil {
|
if m.properties.Libs != nil {
|
||||||
// TODO 244210934 ALIX Check if this else statement breaks presubmits get rid of it if it doesn't
|
for _, d := range m.properties.Libs {
|
||||||
modType := ctx.ModuleType()
|
neverlinkLabel := android.BazelLabelForModuleDepSingle(ctx, d)
|
||||||
if strings.HasPrefix(modType, "java_binary") || strings.HasPrefix(modType, "java_library") || modType == "android_app" || modType == "android_library" || modType == "java_plugin" {
|
neverlinkLabel.Label = neverlinkLabel.Label + "-neverlink"
|
||||||
for _, d := range m.properties.Libs {
|
deps.Add(&neverlinkLabel)
|
||||||
neverlinkLabel := android.BazelLabelForModuleDepSingle(ctx, d)
|
|
||||||
neverlinkLabel.Label = neverlinkLabel.Label + "-neverlink"
|
|
||||||
deps.Add(&neverlinkLabel)
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
deps.Append(android.BazelLabelForModuleDeps(ctx, android.LastUniqueStrings(android.CopyOf(m.properties.Libs))))
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user