diff options
author | Colin Cross <ccross@android.com> | 2019-04-02 16:10:56 -0700 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2019-04-02 23:18:30 +0000 |
commit | ff0daf4ccf2f1ef65dad34a971a1f3c65827f744 (patch) | |
tree | d39ed037e1b949afb6283157b9058d98b7f80b1d /android | |
parent | 9a4f3f7ea87d983ddf69831a9e197f6b62d4d873 (diff) | |
download | soong-ff0daf4ccf2f1ef65dad34a971a1f3c65827f744.tar.gz |
Fix sdk_version: "system_current" when Platform_sdk_final=true
When PLATFORM_VERSION_CODENAME is set to REL Platform_sdk_final
becomes true, which causes the return value of sdkVersionToNumber
for "system_current" to a real version number instead of
FutureApiLevel. This enables the check against
PlatformSystemSdkVersions, which doesn't contain "current". Use
the numeric value instead.
Fixes: 129786845
Test: sdk_test.go
Change-Id: If7cf211cc01c5fbf3e3ece3c3f604718a13d5a9b
Diffstat (limited to 'android')
-rw-r--r-- | android/config.go | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/android/config.go b/android/config.go index fff77ca88..2e0750b7b 100644 --- a/android/config.go +++ b/android/config.go @@ -200,12 +200,14 @@ func saveToConfigFile(config jsonConfigurable, filename string) error { func TestConfig(buildDir string, env map[string]string) Config { config := &config{ productVariables: productVariables{ - DeviceName: stringPtr("test_device"), - Platform_sdk_version: intPtr(26), - AAPTConfig: []string{"normal", "large", "xlarge", "hdpi", "xhdpi", "xxhdpi"}, - AAPTPreferredConfig: stringPtr("xhdpi"), - AAPTCharacteristics: stringPtr("nosdcard"), - AAPTPrebuiltDPI: []string{"xhdpi", "xxhdpi"}, + DeviceName: stringPtr("test_device"), + Platform_sdk_version: intPtr(26), + DeviceSystemSdkVersions: []string{"14", "15"}, + Platform_systemsdk_versions: []string{"25", "26"}, + AAPTConfig: []string{"normal", "large", "xlarge", "hdpi", "xhdpi", "xxhdpi"}, + AAPTPreferredConfig: stringPtr("xhdpi"), + AAPTCharacteristics: stringPtr("nosdcard"), + AAPTPrebuiltDPI: []string{"xhdpi", "xxhdpi"}, }, buildDir: buildDir, |