Add min_sdk_version to android_library_import modules

pom2bp now inserts a min_sdk_version into android_library_import
modules.

Bug: 110848854
Test: m checkbuild
Change-Id: I1396eabd8bfa02755c829ddac03022ffb7a5673e
This commit is contained in:
Colin Cross 2018-07-10 13:39:30 -07:00
parent 461ba49a0a
commit 479884c93d
1 changed files with 5 additions and 1 deletions

View File

@ -336,7 +336,8 @@ func AndroidLibraryFactory() android.Module {
type AARImportProperties struct {
Aars []string
Sdk_version *string
Sdk_version *string
Min_sdk_version *string
Static_libs []string
Libs []string
@ -362,6 +363,9 @@ func (a *AARImport) sdkVersion() string {
}
func (a *AARImport) minSdkVersion() string {
if a.properties.Min_sdk_version != nil {
return *a.properties.Min_sdk_version
}
return a.sdkVersion()
}