Merge "Override EarlyModuleContext.Namespace"
This commit is contained in:
@@ -97,6 +97,8 @@ type EarlyModuleContext interface {
|
|||||||
GlobFiles(globPattern string, excludes []string) Paths
|
GlobFiles(globPattern string, excludes []string) Paths
|
||||||
IsSymlink(path Path) bool
|
IsSymlink(path Path) bool
|
||||||
Readlink(path Path) string
|
Readlink(path Path) string
|
||||||
|
|
||||||
|
Namespace() *Namespace
|
||||||
}
|
}
|
||||||
|
|
||||||
// BaseModuleContext is the same as blueprint.BaseModuleContext except that Config() returns
|
// BaseModuleContext is the same as blueprint.BaseModuleContext except that Config() returns
|
||||||
@@ -219,7 +221,6 @@ type ModuleContext interface {
|
|||||||
VisitAllModuleVariants(visit func(Module))
|
VisitAllModuleVariants(visit func(Module))
|
||||||
|
|
||||||
GetMissingDependencies() []string
|
GetMissingDependencies() []string
|
||||||
Namespace() blueprint.Namespace
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type Module interface {
|
type Module interface {
|
||||||
@@ -1187,7 +1188,7 @@ func (m *ModuleBase) generateModuleTarget(ctx ModuleContext) {
|
|||||||
|
|
||||||
var deps Paths
|
var deps Paths
|
||||||
|
|
||||||
namespacePrefix := ctx.Namespace().(*Namespace).id
|
namespacePrefix := ctx.Namespace().id
|
||||||
if namespacePrefix != "" {
|
if namespacePrefix != "" {
|
||||||
namespacePrefix = namespacePrefix + "-"
|
namespacePrefix = namespacePrefix + "-"
|
||||||
}
|
}
|
||||||
@@ -1498,6 +1499,10 @@ func (e *earlyModuleContext) SystemExtSpecific() bool {
|
|||||||
return e.kind == systemExtSpecificModule
|
return e.kind == systemExtSpecificModule
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (e *earlyModuleContext) Namespace() *Namespace {
|
||||||
|
return e.EarlyModuleContext.Namespace().(*Namespace)
|
||||||
|
}
|
||||||
|
|
||||||
type baseModuleContext struct {
|
type baseModuleContext struct {
|
||||||
bp blueprint.BaseModuleContext
|
bp blueprint.BaseModuleContext
|
||||||
earlyModuleContext
|
earlyModuleContext
|
||||||
|
Reference in New Issue
Block a user