Merge "Use product variables from the overridden apex" am: ae3e4cc2fd
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2477957 Change-Id: I30240a9e42aa4a1ce671af59b2ea05b86c76bee5 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -1334,7 +1334,7 @@ func (attrs *CommonAttributes) fillCommonBp2BuildModuleAttrs(ctx *topDownMutator
|
||||
// Check product variables for `enabled: true` flag override.
|
||||
// Returns a list of the constraint_value targets who enable this override.
|
||||
func productVariableConfigEnableLabels(ctx *topDownMutatorContext) []bazel.Label {
|
||||
productVariableProps := ProductVariableProperties(ctx)
|
||||
productVariableProps := ProductVariableProperties(ctx, ctx.Module())
|
||||
productConfigEnablingTargets := []bazel.Label{}
|
||||
const propName = "Enabled"
|
||||
if productConfigProps, exists := productVariableProps[propName]; exists {
|
||||
|
@@ -663,9 +663,8 @@ func (p *ProductConfigProperty) SelectKey() string {
|
||||
type ProductConfigProperties map[string]map[ProductConfigProperty]interface{}
|
||||
|
||||
// ProductVariableProperties returns a ProductConfigProperties containing only the properties which
|
||||
// have been set for the module in the given context.
|
||||
func ProductVariableProperties(ctx BazelConversionPathContext) ProductConfigProperties {
|
||||
module := ctx.Module()
|
||||
// have been set for the given module.
|
||||
func ProductVariableProperties(ctx ArchVariantContext, module Module) ProductConfigProperties {
|
||||
moduleBase := module.base()
|
||||
|
||||
productConfigProperties := ProductConfigProperties{}
|
||||
|
Reference in New Issue
Block a user