soong: Add `aapt_version_code` default
This appends `--version_code=$(date -u +%Y%m%d)` to aapt flags, which is useful for flushing some caches upon system updates. Change-Id: I6575b878f09c1c3138e12abc34d39405f51245e7 Signed-off-by: Omkar Chandorkar <gotenksIN@aospa.co>
This commit is contained in:
parent
3e7497f25a
commit
43d2a1b26f
|
@ -154,3 +154,23 @@ uses_miui_camera {
|
|||
},
|
||||
},
|
||||
}
|
||||
|
||||
soong_config_module_type {
|
||||
name: "aapt_version_code",
|
||||
module_type: "java_defaults",
|
||||
config_namespace: "aospaGlobalVars",
|
||||
value_variables: ["aapt_version_code"],
|
||||
properties: ["aaptflags"],
|
||||
}
|
||||
|
||||
aapt_version_code {
|
||||
name: "aapt_version_code_defaults",
|
||||
soong_config_variables: {
|
||||
aapt_version_code: {
|
||||
aaptflags: [
|
||||
"--version-code",
|
||||
"%s",
|
||||
],
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
@ -17,6 +17,7 @@ $(foreach v,$(EXPORT_TO_SOONG),$(eval $(call addVar,$(v))))
|
|||
|
||||
SOONG_CONFIG_NAMESPACES += aospaGlobalVars
|
||||
SOONG_CONFIG_aospaGlobalVars += \
|
||||
aapt_version_code \
|
||||
needs_camera_boottime \
|
||||
powershare_node \
|
||||
target_init_vendor_lib \
|
||||
|
@ -32,6 +33,7 @@ TARGET_INIT_VENDOR_LIB ?= vendor_init
|
|||
TARGET_SURFACEFLINGER_UDFPS_LIB ?= surfaceflinger_udfps_lib
|
||||
|
||||
# Soong value variables
|
||||
SOONG_CONFIG_aospaGlobalVars_aapt_version_code := $(shell date -u +%Y%m%d)
|
||||
SOONG_CONFIG_aospaGlobalVars_needs_camera_boottime := $(TARGET_CAMERA_BOOTTIME_TIMESTAMP)
|
||||
SOONG_CONFIG_aospaGlobalVars_powershare_node := $(TARGET_POWERSHARE_NODE)
|
||||
SOONG_CONFIG_aospaGlobalVars_target_init_vendor_lib := $(TARGET_INIT_VENDOR_LIB)
|
||||
|
|
Loading…
Reference in New Issue