Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 1 | local_c_flags := -DUSE_OPENSSL_PBKDF2 |
| 2 | |
Ethan Yonker | c798c9c | 2015-10-09 11:15:26 -0500 | [diff] [blame] | 3 | local_c_includes := $(log_c_includes) external/openssl/include external/boringssl/src/include |
Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 4 | |
| 5 | local_additional_dependencies := $(LOCAL_PATH)/android-config.mk $(LOCAL_PATH)/Scrypt.mk |
| 6 | |
| 7 | include $(LOCAL_PATH)/Scrypt-config.mk |
| 8 | |
| 9 | ####################################### |
| 10 | # target static library |
| 11 | include $(CLEAR_VARS) |
| 12 | include $(LOCAL_PATH)/android-config.mk |
| 13 | |
| 14 | LOCAL_SHARED_LIBRARIES := $(log_shared_libraries) |
| 15 | |
| 16 | # If we're building an unbundled build, don't try to use clang since it's not |
| 17 | # in the NDK yet. This can be removed when a clang version that is fast enough |
| 18 | # in the NDK. |
| 19 | ifeq (,$(TARGET_BUILD_APPS)) |
| 20 | LOCAL_CLANG := true |
| 21 | else |
| 22 | LOCAL_SDK_VERSION := 9 |
| 23 | endif |
| 24 | |
| 25 | LOCAL_SRC_FILES += $(target_src_files) |
| 26 | LOCAL_CFLAGS += $(target_c_flags) |
Ethan Yonker | b789626 | 2014-12-18 15:30:31 -0600 | [diff] [blame] | 27 | LOCAL_C_INCLUDES += $(target_c_includes) $(commands_recovery_local_path)/crypto/scrypt/lib/util |
Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 28 | LOCAL_MODULE_TAGS := optional |
| 29 | LOCAL_MODULE:= libscrypttwrp_static |
Ethan Yonker | abf1fb0 | 2019-04-24 16:09:07 -0500 | [diff] [blame] | 30 | ifeq ($(shell test $(PLATFORM_SDK_VERSION) -ge 28; echo $$?),0) |
| 31 | LOCAL_REQUIRED_MODULES := $(local_additional_dependencies) |
| 32 | else |
| 33 | LOCAL_ADDITIONAL_DEPENDENCIES := $(local_additional_dependencies) |
| 34 | endif |
Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 35 | include $(BUILD_STATIC_LIBRARY) |
| 36 | |
| 37 | ######################################## |
| 38 | # host static library |
| 39 | |
| 40 | include $(CLEAR_VARS) |
| 41 | include $(LOCAL_PATH)/android-config.mk |
| 42 | LOCAL_SHARED_LIBRARIES := $(log_shared_libraries) |
| 43 | LOCAL_SRC_FILES += $(host_src_files) |
| 44 | LOCAL_CFLAGS += $(host_c_flags) |
Ethan Yonker | b789626 | 2014-12-18 15:30:31 -0600 | [diff] [blame] | 45 | LOCAL_C_INCLUDES += $(host_c_includes) $(commands_recovery_local_path)/crypto/scrypt/lib/util |
Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 46 | LOCAL_LDLIBS += -ldl |
| 47 | LOCAL_MODULE_TAGS := optional |
| 48 | LOCAL_MODULE:= libscrypttwrp_static |
Ethan Yonker | abf1fb0 | 2019-04-24 16:09:07 -0500 | [diff] [blame] | 49 | ifeq ($(shell test $(PLATFORM_SDK_VERSION) -ge 28; echo $$?),0) |
| 50 | LOCAL_REQUIRED_MODULES := $(local_additional_dependencies) |
| 51 | else |
| 52 | LOCAL_ADDITIONAL_DEPENDENCIES := $(local_additional_dependencies) |
| 53 | endif |
Dees Troy | 4dff2e6 | 2013-11-10 04:11:43 +0000 | [diff] [blame] | 54 | include $(BUILD_HOST_STATIC_LIBRARY) |