forked from openkylin/platform_build
Merge "Move build number file to out/soong" am: 47b08fbab5
am: 87f76601de
Change-Id: I268b7f7d214b140adef9cddd7161815ed9e54cea
This commit is contained in:
commit
f5504ac259
|
@ -820,7 +820,7 @@ else
|
||||||
MAINLINE_SEPOLICY_DEV_CERTIFICATES := $(dir $(DEFAULT_SYSTEM_DEV_CERTIFICATE))
|
MAINLINE_SEPOLICY_DEV_CERTIFICATES := $(dir $(DEFAULT_SYSTEM_DEV_CERTIFICATE))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
BUILD_NUMBER_FROM_FILE := $$(cat $(OUT_DIR)/build_number.txt)
|
BUILD_NUMBER_FROM_FILE := $$(cat $(SOONG_OUT_DIR)/build_number.txt)
|
||||||
BUILD_DATETIME_FROM_FILE := $$(cat $(BUILD_DATETIME_FILE))
|
BUILD_DATETIME_FROM_FILE := $$(cat $(BUILD_DATETIME_FILE))
|
||||||
|
|
||||||
# SEPolicy versions
|
# SEPolicy versions
|
||||||
|
|
|
@ -38,11 +38,13 @@ include $(BUILD_SYSTEM)/clang/config.mk
|
||||||
# Write the build number to a file so it can be read back in
|
# Write the build number to a file so it can be read back in
|
||||||
# without changing the command line every time. Avoids rebuilds
|
# without changing the command line every time. Avoids rebuilds
|
||||||
# when using ninja.
|
# when using ninja.
|
||||||
$(shell mkdir -p $(OUT_DIR) && \
|
$(shell mkdir -p $(SOONG_OUT_DIR) && \
|
||||||
echo -n $(BUILD_NUMBER) > $(OUT_DIR)/build_number.txt)
|
echo -n $(BUILD_NUMBER) > $(SOONG_OUT_DIR)/build_number.txt)
|
||||||
BUILD_NUMBER_FILE := $(OUT_DIR)/build_number.txt
|
BUILD_NUMBER_FILE := $(SOONG_OUT_DIR)/build_number.txt
|
||||||
.KATI_READONLY := BUILD_NUMBER_FILE
|
.KATI_READONLY := BUILD_NUMBER_FILE
|
||||||
$(KATI_obsolete_var BUILD_NUMBER,See https://android.googlesource.com/platform/build/+/master/Changes.md#BUILD_NUMBER)
|
$(KATI_obsolete_var BUILD_NUMBER,See https://android.googlesource.com/platform/build/+/master/Changes.md#BUILD_NUMBER)
|
||||||
|
$(BUILD_NUMBER_FILE):
|
||||||
|
touch $@
|
||||||
|
|
||||||
DATE_FROM_FILE := date -d @$(BUILD_DATETIME_FROM_FILE)
|
DATE_FROM_FILE := date -d @$(BUILD_DATETIME_FROM_FILE)
|
||||||
.KATI_READONLY := DATE_FROM_FILE
|
.KATI_READONLY := DATE_FROM_FILE
|
||||||
|
|
|
@ -25,7 +25,7 @@ $(call json_start)
|
||||||
$(call add_json_str, Make_suffix, -$(TARGET_PRODUCT))
|
$(call add_json_str, Make_suffix, -$(TARGET_PRODUCT))
|
||||||
|
|
||||||
$(call add_json_str, BuildId, $(BUILD_ID))
|
$(call add_json_str, BuildId, $(BUILD_ID))
|
||||||
$(call add_json_str, BuildNumberFromFile, $(BUILD_NUMBER_FROM_FILE))
|
$(call add_json_str, BuildNumberFile, build_number.txt)
|
||||||
|
|
||||||
$(call add_json_str, Platform_version_name, $(PLATFORM_VERSION))
|
$(call add_json_str, Platform_version_name, $(PLATFORM_VERSION))
|
||||||
$(call add_json_val, Platform_sdk_version, $(PLATFORM_SDK_VERSION))
|
$(call add_json_val, Platform_sdk_version, $(PLATFORM_SDK_VERSION))
|
||||||
|
|
Loading…
Reference in New Issue