summaryrefslogtreecommitdiffstats
path: root/core/version_defaults.mk
diff options
context:
space:
mode:
authorAdam Powell <adamp@google.com>2015-05-21 13:49:05 -0700
committerAdam Powell <adamp@google.com>2015-05-21 13:49:05 -0700
commitbdd5e8e7fe6afb14c9b3028fdaa094008ada309c (patch)
treeccb0a94dc8fd2a371442bd99391d8b1f35444712 /core/version_defaults.mk
parent70b67accbfb80c9d238c7b2121f3ba6d1691e2b0 (diff)
downloadbuild-bdd5e8e7fe6afb14c9b3028fdaa094008ada309c.zip
build-bdd5e8e7fe6afb14c9b3028fdaa094008ada309c.tar.gz
build-bdd5e8e7fe6afb14c9b3028fdaa094008ada309c.tar.bz2
Initialize ro.build.version.preview_sdk
Set the initial (version 1!) value for the preview SDK version readable by apps. If we're on a release version, force it to be 0. Change-Id: Ib3e6cad1f59cea8e4a781827d4a35dd3620b90f1
Diffstat (limited to 'core/version_defaults.mk')
-rw-r--r--core/version_defaults.mk17
1 files changed, 17 insertions, 0 deletions
diff --git a/core/version_defaults.mk b/core/version_defaults.mk
index d325fd3..6cbe81c 100644
--- a/core/version_defaults.mk
+++ b/core/version_defaults.mk
@@ -67,6 +67,23 @@ ifeq "" "$(PLATFORM_VERSION_CODENAME)"
PLATFORM_VERSION_ALL_CODENAMES := $(PLATFORM_VERSION_CODENAME)
endif
+ifeq "REL" "$(PLATFORM_VERSION_CODENAME)"
+ PLATFORM_PREVIEW_SDK_VERSION := 0
+else
+ ifeq "" "$(PLATFORM_PREVIEW_SDK_VERSION)"
+ # This is the definition of a preview SDK version over and above the current
+ # platform SDK version. Unlike the platform SDK version, a higher value
+ # for preview SDK version does NOT mean that all prior preview APIs are
+ # included. Packages reading this value to determine compatibility with
+ # known APIs should check that this value is precisely equal to the preview
+ # SDK version the package was built for, otherwise it should fall back to
+ # assuming the device can only support APIs as of the previous official
+ # public release.
+ # This value will always be 0 for release builds.
+ PLATFORM_PREVIEW_SDK_VERSION := 1
+ endif
+endif
+
ifeq "" "$(DEFAULT_APP_TARGET_SDK)"
# This is the default minSdkVersion and targetSdkVersion to use for
# all .apks created by the build system. It can be overridden by explicitly