Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 1 | LOCAL_PATH := $(call my-dir) |
| 2 | |
| 3 | RELINK := $(LOCAL_PATH)/relink.sh |
| 4 | |
| 5 | #dummy file to trigger required modules |
| 6 | include $(CLEAR_VARS) |
| 7 | LOCAL_MODULE := teamwin |
| 8 | LOCAL_MODULE_TAGS := eng |
| 9 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 10 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/sbin |
| 11 | |
| 12 | # Manage list |
| 13 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/dump_image |
| 14 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/flash_image |
| 15 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/erase_image |
| 16 | RELINK_SOURCE_FILES += $(TARGET_OUT_OPTIONAL_EXECUTABLES)/busybox |
| 17 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/pigz |
bigbiff bigbiff | 9c75405 | 2013-01-09 09:09:08 -0500 | [diff] [blame] | 18 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/dosfsck |
| 19 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/dosfslabel |
| 20 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/mkdosfs |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 21 | RELINK_SOURCE_FILES += $(TARGET_OUT_EXECUTABLES)/e2fsck |
| 22 | RELINK_SOURCE_FILES += $(TARGET_OUT_EXECUTABLES)/mke2fs |
| 23 | RELINK_SOURCE_FILES += $(TARGET_OUT_EXECUTABLES)/tune2fs |
| 24 | RELINK_SOURCE_FILES += $(TARGET_OUT_EXECUTABLES)/linker |
| 25 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libc.so |
| 26 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libcutils.so |
| 27 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libdl.so |
| 28 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2_blkid.so |
| 29 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2_com_err.so |
| 30 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2_e2p.so |
| 31 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2fs.so |
| 32 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2_profile.so |
| 33 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext2_uuid.so |
| 34 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/liblog.so |
| 35 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libm.so |
| 36 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libstdc++.so |
| 37 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libz.so |
Dees_Troy | 2673cec | 2013-04-02 20:22:16 +0000 | [diff] [blame] | 38 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libminuitwrp.so |
| 39 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libminadbd.so |
| 40 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libminzip.so |
| 41 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libmtdutils.so |
bigbiff bigbiff | 9c75405 | 2013-01-09 09:09:08 -0500 | [diff] [blame] | 42 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libtar.so |
Vojtech Bocek | 7cc278b | 2013-02-24 01:40:19 +0100 | [diff] [blame] | 43 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libblkid.so |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 44 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libmmcutils.so |
| 45 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libbmlutils.so |
| 46 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libflashutils.so |
| 47 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libstlport.so |
Vojtech Bocek | 8593234 | 2013-04-01 22:11:33 +0200 | [diff] [blame] | 48 | #RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libmincrypt.so |
Dees_Troy | 43d8b00 | 2012-09-17 16:00:01 -0400 | [diff] [blame] | 49 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libext4_utils.so |
Dees_Troy | 2673cec | 2013-04-02 20:22:16 +0000 | [diff] [blame] | 50 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libaosprecovery.so |
Vojtech Bocek | 7cc278b | 2013-02-24 01:40:19 +0100 | [diff] [blame] | 51 | ifeq ($(BUILD_ID), GINGERBREAD) |
| 52 | TW_NO_EXFAT := true |
| 53 | endif |
Dees_Troy | b05ddee | 2013-01-28 20:24:50 +0000 | [diff] [blame] | 54 | ifneq ($(TW_NO_EXFAT), true) |
bigbiff bigbiff | 9c75405 | 2013-01-09 09:09:08 -0500 | [diff] [blame] | 55 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/exfat-fuse |
Dees_Troy | b05ddee | 2013-01-28 20:24:50 +0000 | [diff] [blame] | 56 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/mkexfatfs |
Vojtech Bocek | 7cc278b | 2013-02-24 01:40:19 +0100 | [diff] [blame] | 57 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libexfat.so |
bigbiff bigbiff | 9c75405 | 2013-01-09 09:09:08 -0500 | [diff] [blame] | 58 | endif |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 59 | ifeq ($(TW_INCLUDE_BLOBPACK), true) |
| 60 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/blobpack |
| 61 | endif |
| 62 | ifeq ($(TW_INCLUDE_INJECTTWRP), true) |
| 63 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/injecttwrp |
| 64 | endif |
| 65 | ifeq ($(TW_INCLUDE_DUMLOCK), true) |
| 66 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/htcdumlock |
| 67 | endif |
| 68 | ifeq ($(TW_INCLUDE_CRYPTO), true) |
Dees_Troy | 2673cec | 2013-04-02 20:22:16 +0000 | [diff] [blame] | 69 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libcryptfsics.so |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 70 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libcrypto.so |
| 71 | endif |
| 72 | ifeq ($(TW_INCLUDE_JB_CRYPTO), true) |
Dees_Troy | 2673cec | 2013-04-02 20:22:16 +0000 | [diff] [blame] | 73 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libcryptfsjb.so |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 74 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libcrypto.so |
| 75 | endif |
Dees_Troy | 38bd760 | 2012-09-14 13:33:53 -0400 | [diff] [blame] | 76 | ifeq ($(TARGET_USERIMAGES_USE_EXT4), true) |
| 77 | RELINK_SOURCE_FILES += $(TARGET_OUT_EXECUTABLES)/make_ext4fs |
| 78 | endif |
Dees_Troy | 4546fe7 | 2013-01-10 14:33:27 +0000 | [diff] [blame] | 79 | ifneq ($(wildcard system/core/libsparse/Android.mk),) |
| 80 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libsparse.so |
| 81 | endif |
Dees_Troy | 83bd483 | 2013-05-04 12:39:56 +0000 | [diff] [blame] | 82 | ifneq ($(TW_EXCLUDE_ENCRYPTED_BACKUPS), true) |
| 83 | RELINK_SOURCE_FILES += $(TARGET_RECOVERY_ROOT_OUT)/sbin/openaes |
| 84 | RELINK_SOURCE_FILES += $(TARGET_OUT_SHARED_LIBRARIES)/libopenaes.so |
| 85 | endif |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 86 | |
| 87 | TWRP_AUTOGEN := $(intermediates)/teamwin |
| 88 | |
| 89 | GEN := $(intermediates)/teamwin |
| 90 | $(GEN): $(RELINK) |
| 91 | $(GEN): $(RELINK_SOURCE_FILES) $(call intermediates-dir-for,EXECUTABLES,recovery)/recovery |
| 92 | $(RELINK) $(TARGET_RECOVERY_ROOT_OUT)/sbin $(RELINK_SOURCE_FILES) |
| 93 | $(RELINK) $(call intermediates-dir-for,EXECUTABLES,recovery) $(call intermediates-dir-for,EXECUTABLES,recovery)/recovery |
| 94 | |
| 95 | LOCAL_GENERATED_SOURCES := $(GEN) |
| 96 | LOCAL_SRC_FILES := teamwin $(GEN) |
| 97 | include $(BUILD_PREBUILT) |
| 98 | |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 99 | #fix_permissions |
| 100 | include $(CLEAR_VARS) |
| 101 | LOCAL_MODULE := fix_permissions.sh |
| 102 | LOCAL_MODULE_TAGS := eng |
| 103 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 104 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/sbin |
| 105 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 106 | include $(BUILD_PREBUILT) |
| 107 | |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 108 | #mke2fs.conf |
| 109 | include $(CLEAR_VARS) |
| 110 | LOCAL_MODULE := mke2fs.conf |
| 111 | LOCAL_MODULE_TAGS := eng |
| 112 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 113 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/etc |
| 114 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 115 | include $(BUILD_PREBUILT) |
| 116 | |
| 117 | ifeq ($(BOARD_HAS_NO_REAL_SDCARD),) |
| 118 | #parted |
| 119 | include $(CLEAR_VARS) |
| 120 | LOCAL_MODULE := parted |
| 121 | LOCAL_MODULE_TAGS := eng |
| 122 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 123 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/sbin |
| 124 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 125 | include $(BUILD_PREBUILT) |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 126 | endif |
| 127 | |
Dees_Troy | 83bd483 | 2013-05-04 12:39:56 +0000 | [diff] [blame] | 128 | # copy license file for OpenAES |
| 129 | ifneq ($(TW_EXCLUDE_ENCRYPTED_BACKUPS), true) |
| 130 | include $(CLEAR_VARS) |
| 131 | LOCAL_MODULE := ../openaes/LICENSE |
| 132 | LOCAL_MODULE_TAGS := eng |
| 133 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 134 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/license/openaes |
| 135 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 136 | include $(BUILD_PREBUILT) |
| 137 | endif |
| 138 | |
Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 139 | ifeq ($(TW_INCLUDE_DUMLOCK), true) |
| 140 | #htcdumlock for /system for dumlock |
| 141 | include $(CLEAR_VARS) |
| 142 | LOCAL_MODULE := htcdumlocksys |
| 143 | LOCAL_MODULE_TAGS := eng |
| 144 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 145 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 146 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 147 | include $(BUILD_PREBUILT) |
| 148 | |
| 149 | #flash_image for /system for dumlock |
| 150 | include $(CLEAR_VARS) |
| 151 | LOCAL_MODULE := flash_imagesys |
| 152 | LOCAL_MODULE_TAGS := eng |
| 153 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 154 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 155 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 156 | include $(BUILD_PREBUILT) |
| 157 | |
| 158 | #dump_image for /system for dumlock |
| 159 | include $(CLEAR_VARS) |
| 160 | LOCAL_MODULE := dump_imagesys |
| 161 | LOCAL_MODULE_TAGS := eng |
| 162 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 163 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 164 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 165 | include $(BUILD_PREBUILT) |
| 166 | |
| 167 | #libbmlutils for /system for dumlock |
| 168 | include $(CLEAR_VARS) |
| 169 | LOCAL_MODULE := libbmlutils.so |
| 170 | LOCAL_MODULE_TAGS := eng |
| 171 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 172 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 173 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 174 | include $(BUILD_PREBUILT) |
| 175 | |
| 176 | #libflashutils for /system for dumlock |
| 177 | include $(CLEAR_VARS) |
| 178 | LOCAL_MODULE := libflashutils.so |
| 179 | LOCAL_MODULE_TAGS := eng |
| 180 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 181 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 182 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 183 | include $(BUILD_PREBUILT) |
| 184 | |
| 185 | #libmmcutils for /system for dumlock |
| 186 | include $(CLEAR_VARS) |
| 187 | LOCAL_MODULE := libmmcutils.so |
| 188 | LOCAL_MODULE_TAGS := eng |
| 189 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 190 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 191 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 192 | include $(BUILD_PREBUILT) |
| 193 | |
| 194 | #libmtdutils for /system for dumlock |
| 195 | include $(CLEAR_VARS) |
| 196 | LOCAL_MODULE := libmtdutils.so |
| 197 | LOCAL_MODULE_TAGS := eng |
| 198 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 199 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 200 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 201 | include $(BUILD_PREBUILT) |
| 202 | |
| 203 | #HTCDumlock.apk |
| 204 | include $(CLEAR_VARS) |
| 205 | LOCAL_MODULE := HTCDumlock.apk |
| 206 | LOCAL_MODULE_TAGS := eng |
| 207 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
| 208 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/res/htcd |
| 209 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 210 | include $(BUILD_PREBUILT) |
| 211 | endif |
Dees_Troy | 6ef6635 | 2013-02-21 08:26:57 -0600 | [diff] [blame] | 212 | |
| 213 | ifneq ($(TW_EXCLUDE_SUPERSU), true) |
| 214 | #su binary |
| 215 | include $(CLEAR_VARS) |
| 216 | LOCAL_MODULE := su |
| 217 | LOCAL_MODULE_TAGS := eng |
| 218 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
jt1134 | 113ee73 | 2013-02-22 23:26:10 -0600 | [diff] [blame] | 219 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/supersu |
Dees_Troy | 6ef6635 | 2013-02-21 08:26:57 -0600 | [diff] [blame] | 220 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 221 | include $(BUILD_PREBUILT) |
| 222 | |
| 223 | #SuperSU special installer APK |
| 224 | include $(CLEAR_VARS) |
| 225 | LOCAL_MODULE := Superuser.apk |
| 226 | LOCAL_MODULE_TAGS := eng |
| 227 | LOCAL_MODULE_CLASS := RECOVERY_EXECUTABLES |
jt1134 | 113ee73 | 2013-02-22 23:26:10 -0600 | [diff] [blame] | 228 | LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/supersu |
Dees_Troy | 6ef6635 | 2013-02-21 08:26:57 -0600 | [diff] [blame] | 229 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 230 | include $(BUILD_PREBUILT) |
jt1134 | 113ee73 | 2013-02-22 23:26:10 -0600 | [diff] [blame] | 231 | endif |