Move namespace mutator earlier to support defaults
The prebuilts and defaults mutators start adding some dependencies, so for them to be able to reference imported modules, we need to run the namespace mutator earlier. Test: m nothing Test: Try to use a global defaults module from a namespace Change-Id: I6e853d20e32251d0fd33c8b2dcc26c0695b808fd
This commit is contained in:
parent
ad4692d5af
commit
6e72ef7225
2 changed files with 2 additions and 2 deletions
|
@ -76,6 +76,7 @@ var preArch = []RegisterMutatorFunc{
|
|||
func(ctx RegisterMutatorsContext) {
|
||||
ctx.TopDown("load_hooks", loadHookMutator).Parallel()
|
||||
},
|
||||
RegisterNamespaceMutator,
|
||||
RegisterPrebuiltsPreArchMutators,
|
||||
RegisterDefaultsPreArchMutators,
|
||||
}
|
||||
|
@ -86,7 +87,6 @@ func registerArchMutator(ctx RegisterMutatorsContext) {
|
|||
}
|
||||
|
||||
var preDeps = []RegisterMutatorFunc{
|
||||
RegisterNamespaceMutator,
|
||||
registerArchMutator,
|
||||
}
|
||||
|
||||
|
|
|
@ -606,7 +606,7 @@ func setupTestFromFiles(bps map[string][]byte) (ctx *TestContext, errs []error)
|
|||
ctx.MockFileSystem(bps)
|
||||
ctx.RegisterModuleType("test_module", ModuleFactoryAdaptor(newTestModule))
|
||||
ctx.RegisterModuleType("soong_namespace", ModuleFactoryAdaptor(NamespaceFactory))
|
||||
ctx.PreDepsMutators(RegisterNamespaceMutator)
|
||||
ctx.PreArchMutators(RegisterNamespaceMutator)
|
||||
ctx.Register()
|
||||
|
||||
_, errs = ctx.ParseBlueprintsFiles("Android.bp")
|
||||
|
|
Loading…
Reference in a new issue