Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d2cc5037 authored by Romain Jobredeaux's avatar Romain Jobredeaux
Browse files

Re-order android_app bp2build converter logic.

This change is a no-op but makes it easier to single out framework-res
for conversion in subsequent CL aosp/2720593.

Bug: 276928228
Test: CI
Change-Id: I7c7338add1857697912dec3c34b7c43e06d2d12d
parent edbf854a
Loading
Loading
Loading
Loading
+8 −9
Original line number Diff line number Diff line
@@ -1632,15 +1632,6 @@ type bazelAndroidAppAttributes struct {

// ConvertWithBp2build is used to convert android_app to Bazel.
func (a *AndroidApp) ConvertWithBp2build(ctx android.TopDownMutatorContext) {
	commonAttrs, bp2BuildInfo, supported := a.convertLibraryAttrsBp2Build(ctx)
	if !supported {
		return
	}
	depLabels := bp2BuildInfo.DepLabels

	deps := depLabels.Deps
	deps.Append(depLabels.StaticDeps)

	aapt, supported := a.convertAaptAttrsWithBp2Build(ctx)
	if !supported {
		return
@@ -1711,8 +1702,16 @@ func (a *AndroidApp) ConvertWithBp2build(ctx android.TopDownMutatorContext) {
			})
			appAttrs.Proguard_specs.Add(bazel.MakeLabelAttribute(":" + generatedFlagFileRuleName))
		}
	}

	commonAttrs, bp2BuildInfo, supported := a.convertLibraryAttrsBp2Build(ctx)
	if !supported {
		return
	}
	depLabels := bp2BuildInfo.DepLabels

	deps := depLabels.Deps
	deps.Append(depLabels.StaticDeps)

	props := bazel.BazelTargetModuleProperties{
		Rule_class:        "android_binary",