android_app APEX_GLOBAL_MIN_SDK_VERSION_OVERRIDE
Currently the product variable that is controlled by APEX_GLOBAL_MIN_SDK_VERSION_OVERRIDE only overrides apexes, but it doesn't apply to android_apps. This commit allows android_apps which set updatable: true in their Android.bp to have their min_sdk_version be overriden by this product variable. Bug: 295311875 Test: go test Change-Id: If3cb82a17cae4553b577dd1a4637ee13c3c95302
This commit is contained in:
@@ -934,6 +934,19 @@ func CheckMinSdkVersion(ctx ModuleContext, minSdkVersion ApiLevel, walk WalkPayl
|
||||
})
|
||||
}
|
||||
|
||||
// Construct ApiLevel object from min_sdk_version string value
|
||||
func MinSdkVersionFromValue(ctx EarlyModuleContext, value string) ApiLevel {
|
||||
if value == "" {
|
||||
return NoneApiLevel
|
||||
}
|
||||
apiLevel, err := ApiLevelFromUser(ctx, value)
|
||||
if err != nil {
|
||||
ctx.PropertyErrorf("min_sdk_version", "%s", err.Error())
|
||||
return NoneApiLevel
|
||||
}
|
||||
return apiLevel
|
||||
}
|
||||
|
||||
// Implemented by apexBundle.
|
||||
type ApexTestInterface interface {
|
||||
// Return true if the apex bundle is an apex_test
|
||||
|
Reference in New Issue
Block a user