Merge "Interpret CRT object's min_sdk_version with ApiLevel"
This commit is contained in:
commit
7f6e057f23
1 changed files with 5 additions and 1 deletions
6
cc/cc.go
6
cc/cc.go
|
@ -1970,9 +1970,13 @@ func GetCrtVariations(ctx android.BottomUpMutatorContext,
|
|||
if minSdkVersion == "" || minSdkVersion == "apex_inherit" {
|
||||
minSdkVersion = m.SdkVersion()
|
||||
}
|
||||
apiLevel, err := android.ApiLevelFromUser(ctx, minSdkVersion)
|
||||
if err != nil {
|
||||
ctx.PropertyErrorf("min_sdk_version", err.Error())
|
||||
}
|
||||
return []blueprint.Variation{
|
||||
{Mutator: "sdk", Variation: "sdk"},
|
||||
{Mutator: "version", Variation: minSdkVersion},
|
||||
{Mutator: "version", Variation: apiLevel.String()},
|
||||
}
|
||||
}
|
||||
return []blueprint.Variation{
|
||||
|
|
Loading…
Reference in a new issue