summaryrefslogtreecommitdiffstats
path: root/twrpTarMain/Android.mk
diff options
context:
space:
mode:
authorEthan Yonker <dees_troy@teamw.in>2014-02-11 18:44:06 +0100
committerGerrit Code Review <gerrit2@gerrit>2014-02-12 16:15:11 +0100
commit50381976ff146d25f71c800ebda18a02be456fa2 (patch)
treeb064ea9396bf9df9e586509d8c25dcb4eeec7479 /twrpTarMain/Android.mk
parentAdd rule to make libopenaes_static (diff)
downloadandroid_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar.gz
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar.bz2
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar.lz
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar.xz
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.tar.zst
android_bootable_recovery-50381976ff146d25f71c800ebda18a02be456fa2.zip
Diffstat (limited to '')
-rw-r--r--twrpTarMain/Android.mk71
1 files changed, 71 insertions, 0 deletions
diff --git a/twrpTarMain/Android.mk b/twrpTarMain/Android.mk
new file mode 100644
index 000000000..5cd6fe109
--- /dev/null
+++ b/twrpTarMain/Android.mk
@@ -0,0 +1,71 @@
+LOCAL_PATH:= $(call my-dir)
+
+# Build static binary
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES:= \
+ twrpTarMain.cpp \
+ ../twrp-functions.cpp \
+ ../twrpTar.cpp \
+ ../tarWrite.c \
+ ../twrpDU.cpp
+LOCAL_CFLAGS:= -g -c -W -DBUILD_TWRPTAR_MAIN
+
+LOCAL_C_INCLUDES += bionic external/stlport/stlport
+LOCAL_STATIC_LIBRARIES := libc libtar_static libstlport_static libstdc++
+
+ifeq ($(TWHAVE_SELINUX), true)
+ LOCAL_C_INCLUDES += external/libselinux/include
+ LOCAL_STATIC_LIBRARIES += libselinux
+ LOCAL_CFLAGS += -DHAVE_SELINUX -g
+endif
+ifneq ($(RECOVERY_SDCARD_ON_DATA),)
+ LOCAL_CFLAGS += -DRECOVERY_SDCARD_ON_DATA
+endif
+ifeq ($(TW_EXCLUDE_ENCRYPTED_BACKUPS), true)
+ LOCAL_CFLAGS += -DTW_EXCLUDE_ENCRYPTED_BACKUPS
+else
+ LOCAL_STATIC_LIBRARIES += libopenaes_static
+endif
+
+LOCAL_MODULE:= twrpTar_static
+LOCAL_FORCE_STATIC_EXECUTABLE := true
+LOCAL_MODULE_TAGS:= eng
+LOCAL_MODULE_CLASS := UTILITY_EXECUTABLES
+LOCAL_MODULE_PATH := $(PRODUCT_OUT)/utilities
+include $(BUILD_EXECUTABLE)
+
+
+# Build shared binary
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES:= \
+ twrpTarMain.cpp \
+ ../twrp-functions.cpp \
+ ../twrpTar.cpp \
+ ../tarWrite.c \
+ ../twrpDU.cpp
+LOCAL_CFLAGS:= -g -c -W -DBUILD_TWRPTAR_MAIN
+
+LOCAL_C_INCLUDES += bionic external/stlport/stlport
+LOCAL_SHARED_LIBRARIES := libc libtar libstlport libstdc++
+
+ifeq ($(TWHAVE_SELINUX), true)
+ LOCAL_C_INCLUDES += external/libselinux/include
+ LOCAL_SHARED_LIBRARIES += libselinux
+ LOCAL_CFLAGS += -DHAVE_SELINUX -g
+endif
+ifneq ($(RECOVERY_SDCARD_ON_DATA),)
+ LOCAL_CFLAGS += -DRECOVERY_SDCARD_ON_DATA
+endif
+ifeq ($(TW_EXCLUDE_ENCRYPTED_BACKUPS), true)
+ LOCAL_CFLAGS += -DTW_EXCLUDE_ENCRYPTED_BACKUPS
+else
+ LOCAL_SHARED_LIBRARIES += libopenaes
+endif
+
+LOCAL_MODULE:= twrpTar
+LOCAL_MODULE_TAGS:= eng
+LOCAL_MODULE_CLASS := UTILITY_EXECUTABLES
+LOCAL_MODULE_PATH := $(PRODUCT_OUT)/utilities
+include $(BUILD_EXECUTABLE)