Build starter on Android.
authorTobias Brunner <tobias@strongswan.org>
Tue, 11 Oct 2011 14:19:45 +0000 (16:19 +0200)
committerTobias Brunner <tobias@strongswan.org>
Tue, 11 Oct 2011 14:30:20 +0000 (16:30 +0200)
Android.mk.in
src/starter/Android.mk [new file with mode: 0644]
src/starter/Makefile.am

index bae5318..b52a13b 100644 (file)
@@ -60,6 +60,7 @@ strongswan_CFLAGS := \
        -DCAPABILITIES_NATIVE \
        -DMONOLITHIC \
        -DUSE_VSTR \
+       -DDEBUG \
        -DROUTING_TABLE=0 \
        -DROUTING_TABLE_PRIO=220 \
        -DVERSION=\"$(strongswan_VERSION)\" \
@@ -84,4 +85,5 @@ include $(addprefix $(LOCAL_PATH)/src/,$(addsuffix /Android.mk, \
                libtncif \
                libfreeswan \
                stroke \
+               starter \
        ))
diff --git a/src/starter/Android.mk b/src/starter/Android.mk
new file mode 100644 (file)
index 0000000..2c5c65a
--- /dev/null
@@ -0,0 +1,35 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# copy-n-paste from Makefile.am (update for LEX/YACC)
+LOCAL_SRC_FILES := \
+parser.c lexer.c ipsec-parser.h netkey.c args.h netkey.h \
+starterwhack.c starterwhack.h starterstroke.c invokepluto.c confread.c \
+starterstroke.h interfaces.c invokepluto.h confread.h interfaces.h args.c \
+keywords.c files.h keywords.h cmp.c starter.c cmp.h exec.c invokecharon.c \
+exec.h invokecharon.h loglite.c klips.c klips.h
+
+# build starter ----------------------------------------------------------------
+
+LOCAL_C_INCLUDES += \
+       $(libvstr_PATH) \
+       $(strongswan_PATH)/src/libhydra \
+       $(strongswan_PATH)/src/libfreeswan \
+       $(strongswan_PATH)/src/libstrongswan \
+       $(strongswan_PATH)/src/libfreeswan \
+       $(strongswan_PATH)/src/pluto \
+       $(strongswan_PATH)/src/whack \
+       $(strongswan_PATH)/src/stroke
+
+LOCAL_CFLAGS := $(strongswan_CFLAGS) -DSTART_CHARON -DSTART_PLUTO
+
+LOCAL_MODULE := starter
+
+LOCAL_ARM_MODE := arm
+
+LOCAL_PRELINK_MODULE := false
+
+LOCAL_SHARED_LIBRARIES += libstrongswan libfreeswan
+
+include $(BUILD_EXECUTABLE)
+
index d676d1d..638f206 100644 (file)
@@ -1,6 +1,6 @@
 ipsec_PROGRAMS = starter
 starter_SOURCES = \
-netkey.c parser.y lexer.l ipsec-parser.h args.h netkey.h \
+parser.y lexer.l ipsec-parser.h netkey.c args.h netkey.h \
 starterwhack.c starterwhack.h starterstroke.c invokepluto.c confread.c \
 starterstroke.h interfaces.c invokepluto.h confread.h interfaces.h args.c \
 keywords.c files.h keywords.h cmp.c starter.c cmp.h exec.c invokecharon.c \