Merge "Generate api_levels.json from the preview codenames." am: a910e10b76
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2509782 Change-Id: Icaaf7ea6813ce113a40d465c7c190ba8e81bae76 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -466,7 +466,7 @@ func GetApiLevelsMap(config Config) map[string]int {
|
|||||||
// https://cs.android.com/android/platform/superproject/+/master:build/bazel/rules/common/api.bzl;l=23;drc=231c7e8c8038fd478a79eb68aa5b9f5c64e0e061
|
// https://cs.android.com/android/platform/superproject/+/master:build/bazel/rules/common/api.bzl;l=23;drc=231c7e8c8038fd478a79eb68aa5b9f5c64e0e061
|
||||||
return config.Once(apiLevelsMapKey, func() interface{} {
|
return config.Once(apiLevelsMapKey, func() interface{} {
|
||||||
apiLevelsMap := getApiLevelsMapReleasedVersions()
|
apiLevelsMap := getApiLevelsMapReleasedVersions()
|
||||||
for i, codename := range config.PlatformVersionActiveCodenames() {
|
for i, codename := range config.PlatformVersionAllPreviewCodenames() {
|
||||||
apiLevelsMap[codename] = previewAPILevelBase + i
|
apiLevelsMap[codename] = previewAPILevelBase + i
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -923,6 +923,11 @@ func (c *config) PlatformVersionActiveCodenames() []string {
|
|||||||
return c.productVariables.Platform_version_active_codenames
|
return c.productVariables.Platform_version_active_codenames
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// All unreleased codenames.
|
||||||
|
func (c *config) PlatformVersionAllPreviewCodenames() []string {
|
||||||
|
return c.productVariables.Platform_version_all_preview_codenames
|
||||||
|
}
|
||||||
|
|
||||||
func (c *config) ProductAAPTConfig() []string {
|
func (c *config) ProductAAPTConfig() []string {
|
||||||
return c.productVariables.AAPTConfig
|
return c.productVariables.AAPTConfig
|
||||||
}
|
}
|
||||||
|
@@ -199,6 +199,7 @@ type productVariables struct {
|
|||||||
Platform_sdk_extension_version *int `json:",omitempty"`
|
Platform_sdk_extension_version *int `json:",omitempty"`
|
||||||
Platform_base_sdk_extension_version *int `json:",omitempty"`
|
Platform_base_sdk_extension_version *int `json:",omitempty"`
|
||||||
Platform_version_active_codenames []string `json:",omitempty"`
|
Platform_version_active_codenames []string `json:",omitempty"`
|
||||||
|
Platform_version_all_preview_codenames []string `json:",omitempty"`
|
||||||
Platform_vndk_version *string `json:",omitempty"`
|
Platform_vndk_version *string `json:",omitempty"`
|
||||||
Platform_systemsdk_versions []string `json:",omitempty"`
|
Platform_systemsdk_versions []string `json:",omitempty"`
|
||||||
Platform_security_patch *string `json:",omitempty"`
|
Platform_security_patch *string `json:",omitempty"`
|
||||||
@@ -481,13 +482,14 @@ func (v *productVariables) SetDefaultConfig() {
|
|||||||
*v = productVariables{
|
*v = productVariables{
|
||||||
BuildNumberFile: stringPtr("build_number.txt"),
|
BuildNumberFile: stringPtr("build_number.txt"),
|
||||||
|
|
||||||
Platform_version_name: stringPtr("S"),
|
Platform_version_name: stringPtr("S"),
|
||||||
Platform_base_sdk_extension_version: intPtr(30),
|
Platform_base_sdk_extension_version: intPtr(30),
|
||||||
Platform_sdk_version: intPtr(30),
|
Platform_sdk_version: intPtr(30),
|
||||||
Platform_sdk_codename: stringPtr("S"),
|
Platform_sdk_codename: stringPtr("S"),
|
||||||
Platform_sdk_final: boolPtr(false),
|
Platform_sdk_final: boolPtr(false),
|
||||||
Platform_version_active_codenames: []string{"S"},
|
Platform_version_active_codenames: []string{"S"},
|
||||||
Platform_vndk_version: stringPtr("S"),
|
Platform_version_all_preview_codenames: []string{"S"},
|
||||||
|
Platform_vndk_version: stringPtr("S"),
|
||||||
|
|
||||||
HostArch: stringPtr("x86_64"),
|
HostArch: stringPtr("x86_64"),
|
||||||
HostSecondaryArch: stringPtr("x86"),
|
HostSecondaryArch: stringPtr("x86"),
|
||||||
|
Reference in New Issue
Block a user