Skip to content

Commit

Permalink
Merge "Remove prebuilt_apex_module_creator mutator" into main am: e…
Browse files Browse the repository at this point in the history
…defa90 am: faa827d

Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3277436

Change-Id: I7354bcbc135ac73577c4a35005e69c7507892fab
Signed-off-by: Automerger Merge Worker <[email protected]>
  • Loading branch information
dasspandan authored and android-build-merge-worker-robot committed Sep 24, 2024
2 parents 6dbdcce + faa827d commit 3961bb8
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 27 deletions.
5 changes: 0 additions & 5 deletions apex/apex.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,10 @@ func registerApexBuildComponents(ctx android.RegistrationContext) {
ctx.RegisterModuleType("override_apex", OverrideApexFactory)
ctx.RegisterModuleType("apex_set", apexSetFactory)

ctx.PreArchMutators(registerPreArchMutators)
ctx.PreDepsMutators(RegisterPreDepsMutators)
ctx.PostDepsMutators(RegisterPostDepsMutators)
}

func registerPreArchMutators(ctx android.RegisterMutatorsContext) {
ctx.BottomUp("prebuilt_apex_module_creator", prebuiltApexModuleCreatorMutator).Parallel()
}

func RegisterPreDepsMutators(ctx android.RegisterMutatorsContext) {
ctx.BottomUp("apex_vndk_deps", apexVndkDepsMutator).Parallel()
}
Expand Down
22 changes: 0 additions & 22 deletions apex/prebuilt.go
Original file line number Diff line number Diff line change
Expand Up @@ -253,28 +253,6 @@ func (p *prebuiltCommon) AndroidMkEntries() []android.AndroidMkEntries {
return entriesList
}

// DEPRECATED. // TODO (spandandas): Remove this interface.

// prebuiltApexModuleCreator defines the methods that need to be implemented by prebuilt_apex and
// apex_set in order to create the modules needed to provide access to the prebuilt .apex file.
type prebuiltApexModuleCreator interface {
createPrebuiltApexModules(ctx android.BottomUpMutatorContext)
}

// prebuiltApexModuleCreatorMutator is the mutator responsible for invoking the
// prebuiltApexModuleCreator's createPrebuiltApexModules method.
//
// It is registered as a pre-arch mutator as it must run after the ComponentDepsMutator because it
// will need to access dependencies added by that (exported modules) but must run before the
// DepsMutator so that the deapexer module it creates can add dependencies onto itself from the
// exported modules.
func prebuiltApexModuleCreatorMutator(ctx android.BottomUpMutatorContext) {
module := ctx.Module()
if creator, ok := module.(prebuiltApexModuleCreator); ok {
creator.createPrebuiltApexModules(ctx)
}
}

func (p *prebuiltCommon) hasExportedDeps() bool {
return len(p.prebuiltCommonProperties.Exported_bootclasspath_fragments) > 0 ||
len(p.prebuiltCommonProperties.Exported_systemserverclasspath_fragments) > 0
Expand Down

0 comments on commit 3961bb8

Please sign in to comment.