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

Commit 733110e7 authored by Alix's avatar Alix Committed by Alix Espino
Browse files

refactor android_app bp2build

Test: bp2build tests and locally built MusicKotlin
Change-Id: Ia5a58b26717a0252e3ae87ea68182e6f2b5c60cf
parent 28f4af79
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -1524,7 +1524,6 @@ func (a *AndroidApp) ConvertWithBp2build(ctx android.TopDownMutatorContext) {
		appAttrs.javaCommonAttributes = commonAttrs
		appAttrs.bazelAapt = aapt
		appAttrs.Deps = deps
		ctx.CreateBazelTargetModule(props, android.CommonAttributes{Name: a.Name()}, appAttrs)
	} else {
		ktName := a.Name() + "_kt"
		commonAttrs.Common_srcs = bazel.MakeLabelListAttribute(android.BazelLabelForModuleSrc(ctx, a.properties.Common_srcs))
@@ -1545,11 +1544,12 @@ func (a *AndroidApp) ConvertWithBp2build(ctx android.TopDownMutatorContext) {

		appAttrs.bazelAapt = &bazelAapt{Manifest: aapt.Manifest}
		appAttrs.Deps = bazel.MakeSingleLabelListAttribute(bazel.Label{Label: ":" + ktName})
	}

	ctx.CreateBazelTargetModule(
		props,
		android.CommonAttributes{Name: a.Name()},
		appAttrs,
	)
	}

}