Handle nameless modules during bp2build conversion.
So far it is `package` module. Test: treehugger Change-Id: Ibf3af0b0bf0a532e2ea1d478275a5ac3784ef170
This commit is contained in:
@@ -1169,7 +1169,9 @@ func (attrs *CommonAttributes) fillCommonBp2BuildModuleAttrs(ctx *topDownMutator
|
||||
mod := ctx.Module().base()
|
||||
// Assert passed-in attributes include Name
|
||||
if len(attrs.Name) == 0 {
|
||||
ctx.ModuleErrorf("CommonAttributes in fillCommonBp2BuildModuleAttrs expects a `.Name`!")
|
||||
if ctx.ModuleType() != "package" {
|
||||
ctx.ModuleErrorf("CommonAttributes in fillCommonBp2BuildModuleAttrs expects a `.Name`!")
|
||||
}
|
||||
}
|
||||
|
||||
depsToLabelList := func(deps []string) bazel.LabelListAttribute {
|
||||
|
Reference in New Issue
Block a user