Allow device files to specify a custom theme

Change-Id: I360f93e70c6a48eed502a5aacd6d8d654ca7b570
This commit is contained in:
Ethan Yonker
2014-04-14 09:27:15 -05:00
committed by Gerrit Code Review
parent 0c9d049b6e
commit 1ecaca7d0b

View File

@@ -98,8 +98,13 @@ LOCAL_MODULE := twrp
LOCAL_MODULE_TAGS := eng
LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES
LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res
TWRP_RES_LOC := $(commands_recovery_local_path)/gui/devices/common/res
TWRP_RES_LOC := $(commands_recovery_local_path)/gui/devices
ifeq ($(TW_CUSTOM_THEME),)
TWRP_THEME_LOC := $(commands_recovery_local_path)/gui/devices/$(DEVICE_RESOLUTION)/res
else
TWRP_THEME_LOC := $(TW_CUSTOM_THEME)
endif
TWRP_RES_GEN := $(intermediates)/twrp
ifneq ($(TW_USE_TOOLBOX), true)
TWRP_SH_TARGET := /sbin/busybox
@@ -109,8 +114,8 @@ endif
$(TWRP_RES_GEN):
mkdir -p $(TARGET_RECOVERY_ROOT_OUT)/res/
cp -fr $(TWRP_RES_LOC)/common/res/* $(TARGET_RECOVERY_ROOT_OUT)/res/
cp -fr $(TWRP_RES_LOC)/$(DEVICE_RESOLUTION)/res/* $(TARGET_RECOVERY_ROOT_OUT)/res/
cp -fr $(TWRP_RES_LOC)/* $(TARGET_RECOVERY_ROOT_OUT)/res/
cp -fr $(TWRP_THEME_LOC)/* $(TARGET_RECOVERY_ROOT_OUT)/res/
mkdir -p $(TARGET_RECOVERY_ROOT_OUT)/sbin/
ln -sf $(TWRP_SH_TARGET) $(TARGET_RECOVERY_ROOT_OUT)/sbin/sh
ln -sf /sbin/pigz $(TARGET_RECOVERY_ROOT_OUT)/sbin/gzip