summaryrefslogtreecommitdiffstats
path: root/Android.mk
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2018-03-21 00:07:39 +0100
committerTianjie Xu <xunchang@google.com>2018-03-23 23:01:36 +0100
commit2b3f80068ece1040ba7c923afe1e70b705535ad5 (patch)
tree4335b0b32e083d91044ca3d54696efa27b902700 /Android.mk
parentMerge "f2fs: support f2fs by setting unmovable bit for package file" am: 28dcad554c am: a0e2a1aa8b (diff)
downloadandroid_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar.gz
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar.bz2
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar.lz
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar.xz
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.tar.zst
android_bootable_recovery-2b3f80068ece1040ba7c923afe1e70b705535ad5.zip
Diffstat (limited to '')
-rw-r--r--Android.mk77
1 files changed, 48 insertions, 29 deletions
diff --git a/Android.mk b/Android.mk
index 56d69c03b..0499a6da8 100644
--- a/Android.mk
+++ b/Android.mk
@@ -53,36 +53,21 @@ LOCAL_STATIC_LIBRARIES := \
include $(BUILD_STATIC_LIBRARY)
-# recovery (static executable)
+# librecovery_ui (static library)
# ===============================
include $(CLEAR_VARS)
-
LOCAL_SRC_FILES := \
- adb_install.cpp \
- device.cpp \
- fuse_sdcard_provider.cpp \
- recovery.cpp \
- roots.cpp \
- rotate_logs.cpp \
screen_ui.cpp \
ui.cpp \
vr_ui.cpp \
- wear_ui.cpp \
+ wear_ui.cpp
-LOCAL_MODULE := recovery
-
-LOCAL_FORCE_STATIC_EXECUTABLE := true
-
-LOCAL_REQUIRED_MODULES := e2fsdroid_static mke2fs_static mke2fs.conf
-
-ifeq ($(TARGET_USERIMAGES_USE_F2FS),true)
-ifeq ($(HOST_OS),linux)
-LOCAL_REQUIRED_MODULES += sload.f2fs mkfs.f2fs
-endif
-endif
+LOCAL_CFLAGS := -Wall -Werror
-LOCAL_CFLAGS += -DRECOVERY_API_VERSION=$(RECOVERY_API_VERSION)
-LOCAL_CFLAGS += -Wall -Werror
+LOCAL_MODULE := librecovery_ui
+LOCAL_STATIC_LIBRARIES := \
+ libminui \
+ libbase
ifneq ($(TARGET_RECOVERY_UI_MARGIN_HEIGHT),)
LOCAL_CFLAGS += -DRECOVERY_UI_MARGIN_HEIGHT=$(TARGET_RECOVERY_UI_MARGIN_HEIGHT)
@@ -132,6 +117,36 @@ else
LOCAL_CFLAGS += -DRECOVERY_UI_VR_STEREO_OFFSET=0
endif
+include $(BUILD_STATIC_LIBRARY)
+
+# recovery (static executable)
+# ===============================
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES := \
+ adb_install.cpp \
+ device.cpp \
+ fuse_sdcard_provider.cpp \
+ recovery.cpp \
+ roots.cpp \
+ rotate_logs.cpp \
+
+
+LOCAL_MODULE := recovery
+
+LOCAL_FORCE_STATIC_EXECUTABLE := true
+
+LOCAL_REQUIRED_MODULES := e2fsdroid_static mke2fs_static mke2fs.conf
+
+ifeq ($(TARGET_USERIMAGES_USE_F2FS),true)
+ifeq ($(HOST_OS),linux)
+LOCAL_REQUIRED_MODULES += sload.f2fs mkfs.f2fs
+endif
+endif
+
+LOCAL_CFLAGS += -DRECOVERY_API_VERSION=$(RECOVERY_API_VERSION)
+LOCAL_CFLAGS += -Wall -Werror
+
LOCAL_C_INCLUDES += \
system/vold \
@@ -148,8 +163,17 @@ LOCAL_STATIC_LIBRARIES := \
libvndksupport \
libbatterymonitor
+LOCAL_STATIC_LIBRARIES += librecovery
+
+# If $(TARGET_RECOVERY_UI_LIB) is defined, the recovery calls make_device() from the
+# $(TARGET_RECOVERY_UI_LIB), which depends on the librecovery_ui.
+ifeq ($(TARGET_RECOVERY_UI_LIB),)
+ LOCAL_SRC_FILES += default_device.cpp
+else
+ LOCAL_STATIC_LIBRARIES += $(TARGET_RECOVERY_UI_LIB)
+endif
+
LOCAL_STATIC_LIBRARIES += \
- librecovery \
libverifier \
libbootloader_message \
libfs_mgr \
@@ -161,6 +185,7 @@ LOCAL_STATIC_LIBRARIES += \
libminadbd \
libasyncio \
libfusesideload \
+ librecovery_ui \
libminui \
libpng \
libcrypto_utils \
@@ -184,12 +209,6 @@ endif
LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/sbin
-ifeq ($(TARGET_RECOVERY_UI_LIB),)
- LOCAL_SRC_FILES += default_device.cpp
-else
- LOCAL_STATIC_LIBRARIES += $(TARGET_RECOVERY_UI_LIB)
-endif
-
ifeq ($(BOARD_CACHEIMAGE_PARTITION_SIZE),)
LOCAL_REQUIRED_MODULES += recovery-persist recovery-refresh
endif