android: Use static version of libcrypto
authorTobias Brunner <tobias@strongswan.org>
Thu, 27 Mar 2014 17:04:18 +0000 (18:04 +0100)
committerTobias Brunner <tobias@strongswan.org>
Fri, 25 Apr 2014 12:26:31 +0000 (14:26 +0200)
System.loadLibrary() searches in system directories first (at least in
recent releases), that is, our own build wouldn't actually get used.

src/frontends/android/src/org/strongswan/android/logic/CharonVpnService.java
src/libstrongswan/Android.mk

index 853de56..e45a7d9 100644 (file)
@@ -660,7 +660,6 @@ public class CharonVpnService extends VpnService implements Runnable
         */
        static
        {
-               System.loadLibrary("crypto");
                System.loadLibrary("strongswan");
 
                if (MainActivity.USE_BYOD)
index 2b58db5..24f0bc5 100644 (file)
@@ -70,7 +70,7 @@ LOCAL_SRC_FILES += $(call add_plugin, nonce)
 LOCAL_SRC_FILES += $(call add_plugin, openssl)
 ifneq ($(call plugin_enabled, openssl),)
 LOCAL_C_INCLUDES += $(openssl_PATH)
-LOCAL_SHARED_LIBRARIES += libcrypto
+LOCAL_STATIC_LIBRARIES += libcrypto_static
 endif
 
 LOCAL_SRC_FILES += $(call add_plugin, pem)