1 LOCAL_PATH
:= $(call my-dir
)
4 # this is the list of plugins that are built into libstrongswan and charon
5 # also these plugins are loaded by default (if not changed in strongswan.conf)
6 strongswan_PLUGINS
:= aes des sha1 sha2 md5 fips-prf random x509 pubkey pkcs1 \
7 pem xcbc hmac gmp kernel-netlink socket-default attr android
9 # helper macros to only add source files for plugins included in the list above
10 plugin_enabled
= $(findstring $(1), $(strongswan_PLUGINS
))
11 add_plugin
= $(if
$(call plugin_enabled
,$(1)), \
12 $(addprefix plugins
/$(subst -,_
,$(strip $(1))/),$(2)))
15 libvstr_PATH
= external
/strongswan-support
/vstr
/include
16 libgmp_PATH
= external
/strongswan-support
/gmp
18 # CFLAGS (partially from a configure run using droid-gcc)
19 strongswan_CFLAGS
:= \
24 -Wno-strict-aliasing \
29 -DHAVE_CLOCK_GETTIME \
30 -DHAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC \
33 -DHAVE_STRUCT_SADB_X_POLICY_SADB_X_POLICY_PRIORITY \
34 -DHAVE_IPSEC_MODE_BEET \
35 -DHAVE_IPSEC_DIR_FWD \
39 -DROUTING_TABLE_PRIO
=220 \
41 -DPLUGINS
='"$(strongswan_PLUGINS)"' \
42 -DIPSEC_DIR
=\"/system
/bin
\" \
43 -DIPSEC_PIDDIR
=\"/data
/misc
/vpn
\" \
44 -DSTRONGSWAN_CONF
=\"/system
/etc
/strongswan.conf
\" \
45 -DDEV_RANDOM
=\"/dev
/random
\" \
46 -DDEV_URANDOM
=\"/dev
/urandom
\"
48 # only for Android 2.0+
49 strongswan_CFLAGS
+= \
52 include $(addprefix $(LOCAL_PATH
)/src
/,$(addsuffix /Android.mk
, \