diff --git a/target/product/version.mk b/target/product/version.mk index 0819d7e9..e19be9aa 100644 --- a/target/product/version.mk +++ b/target/product/version.mk @@ -56,7 +56,15 @@ endif BUILD_DATE := $(shell date -u +%Y%m%d) # AOSPA Version -AOSPA_VERSION := $(AOSPA_MAJOR_VERSION)-$(AOSPA_MINOR_VERSION)-$(AOSPA_BUILD)-$(AOSPA_BUILD_VARIANT)-$(BUILD_DATE) +TMP_AOSPA_VERSION := $(AOSPA_MAJOR_VERSION)- +ifeq ($(filter release,$(AOSPA_BUILD_VARIANT)),) + TMP_AOSPA_VERSION += $(AOSPA_BUILD_VARIANT)- +endif +ifeq ($(filter unofficial,$(AOSPA_BUILD_VARIANT)),) + TMP_AOSPA_VERSION += $(AOSPA_MINOR_VERSION)- +endif +TMP_AOSPA_VERSION += $(AOSPA_BUILD)-$(BUILD_DATE) +AOSPA_VERSION := $(shell echo $(TMP_AOSPA_VERSION) | tr -d '[:space:]') PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \ ro.aospa.version=$(AOSPA_VERSION)