From b58f8d1fed1cfc47760125d23160ca78f364722b Mon Sep 17 00:00:00 2001 From: Kenny Root Date: Fri, 2 Oct 2015 17:37:41 -0700 Subject: DO NOT MERGE ANYWHERE Revert "Whitelist windows modules" This is only needed in the mnc-ub-dev branch to deal with the older build project. This reverts commit 08656b61d075740bfb24ddcce65223146259fc02. Change-Id: I7440e3d6371e6d98f1f77705f8bf374e7f37fbe2 --- Android.mk | 15 ++++++++------- crypto-sources.mk | 13 +++++-------- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/Android.mk b/Android.mk index 5ae544c..339f499 100644 --- a/Android.mk +++ b/Android.mk @@ -49,29 +49,30 @@ include $(BUILD_EXECUTABLE) # Host static library include $(CLEAR_VARS) -LOCAL_IS_HOST_MODULE := true +LOCAL_MODULE_TAGS := optional LOCAL_MODULE := libcrypto_static -LOCAL_MODULE_HOST_OS := darwin linux windows LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/src/include LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk $(LOCAL_PATH)/crypto-sources.mk LOCAL_CFLAGS += -fvisibility=hidden -DBORINGSSL_SHARED_LIBRARY -DBORINGSSL_IMPLEMENTATION -Wno-unused-parameter # Windows and Macs both have problems with assembly files -LOCAL_CFLAGS_darwin += -DOPENSSL_NO_ASM -LOCAL_CFLAGS_windows += -DOPENSSL_NO_ASM +ifneq ($(HOST_OS),linux) +LOCAL_CFLAGS += -DOPENSSL_NO_ASM +endif include $(LOCAL_PATH)/crypto-sources.mk include $(BUILD_HOST_STATIC_LIBRARY) # Host shared library include $(CLEAR_VARS) -LOCAL_IS_HOST_MODULE := true +LOCAL_MODULE_TAGS := optional LOCAL_MODULE := libcrypto-host LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include LOCAL_MULTILIB := both LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk $(LOCAL_PATH)/crypto-sources.mk LOCAL_CFLAGS += -fvisibility=hidden -DBORINGSSL_SHARED_LIBRARY -DBORINGSSL_IMPLEMENTATION -Wno-unused-parameter # Windows and Macs both have problems with assembly files -LOCAL_CFLAGS_darwin += -DOPENSSL_NO_ASM -LOCAL_CFLAGS_windows += -DOPENSSL_NO_ASM +ifneq ($(HOST_OS),linux) +LOCAL_CFLAGS += -DOPENSSL_NO_ASM +endif include $(LOCAL_PATH)/crypto-sources.mk include $(BUILD_HOST_SHARED_LIBRARY) diff --git a/crypto-sources.mk b/crypto-sources.mk index a5b8ba3..d90d109 100644 --- a/crypto-sources.mk +++ b/crypto-sources.mk @@ -4,13 +4,10 @@ include $(LOCAL_PATH)/sources.mk LOCAL_CFLAGS += -I$(LOCAL_PATH)/src/include -I$(LOCAL_PATH)/src/crypto -Wno-unused-parameter -DBORINGSSL_ANDROID_SYSTEM LOCAL_ASFLAGS += -I$(LOCAL_PATH)/src/include -I$(LOCAL_PATH)/src/crypto -Wno-unused-parameter # Do not add in the architecture-specific files if we don't want to build assembly -ifeq ($(LOCAL_IS_HOST_MODULE),true) -LOCAL_SRC_FILES_linux_x86 := $(linux_x86_sources) -LOCAL_SRC_FILES_linux_x86_64 := $(linux_x86_64_sources) -else -LOCAL_SRC_FILES_x86 := $(linux_x86_sources) -LOCAL_SRC_FILES_x86_64 := $(linux_x86_64_sources) -LOCAL_SRC_FILES_arm := $(linux_arm_sources) -LOCAL_SRC_FILES_arm64 := $(linux_aarch64_sources) +ifeq (,$(filter -DOPENSSL_NO_ASM,$(LOCAL_CFLAGS))) +LOCAL_SRC_FILES_x86 = $(linux_x86_sources) +LOCAL_SRC_FILES_x86_64 = $(linux_x86_64_sources) +LOCAL_SRC_FILES_arm = $(linux_arm_sources) +LOCAL_SRC_FILES_arm64 = $(linux_aarch64_sources) endif LOCAL_SRC_FILES += $(crypto_sources) -- cgit v1.1