From 584b977489aa559736963c4ca772c258fd323d8e Mon Sep 17 00:00:00 2001 From: bigbiff bigbiff Date: Thu, 8 Dec 2016 21:21:17 -0500 Subject: TWRP device version string For building through jenkins. Export a variable to the shell so that we don't monkey patch variables.h and keep the git tag clean in the version string. Jenkins will export the variable TW_DEVICE_VERSION=n where n > 0. The makefile will use this variable to show the device string in twrp startup. For mass production builds, omit the environment variable to default to 0. Change-Id: I0d6eb764255d7069c0fb4a378522a009cfe4054f --- orscmd/Android.mk | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'orscmd') diff --git a/orscmd/Android.mk b/orscmd/Android.mk index 9f18c16a7..b132d7360 100644 --- a/orscmd/Android.mk +++ b/orscmd/Android.mk @@ -1,10 +1,16 @@ LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) +ifneq ($(TW_DEVICE_VERSION),) + LOCAL_CFLAGS += -DTW_DEVICE_VERSION='"-$(TW_DEVICE_VERSION)"' +else + LOCAL_CFLAGS += -DTW_DEVICE_VERSION='"-0"' +endif + LOCAL_SRC_FILES:= \ orscmd.cpp -LOCAL_CFLAGS:= -c -W -LOCAL_MODULE:=orscmd +LOCAL_CFLAGS += -c -W +LOCAL_MODULE := orscmd LOCAL_MODULE_STEM := twrp LOCAL_MODULE_TAGS:= eng LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES -- cgit v1.2.3