summaryrefslogtreecommitdiffstats
path: root/bindings/java/android/droid-makefile
diff options
context:
space:
mode:
Diffstat (limited to 'bindings/java/android/droid-makefile')
-rw-r--r--bindings/java/android/droid-makefile76
1 files changed, 76 insertions, 0 deletions
diff --git a/bindings/java/android/droid-makefile b/bindings/java/android/droid-makefile
new file mode 100644
index 0000000..63beb29
--- /dev/null
+++ b/bindings/java/android/droid-makefile
@@ -0,0 +1,76 @@
+APP := lib$(PROJECT)_$(MARCH).$(EXT)
+
+CFLAGS := $(CFLAGS_LIB) -fno-rtti -fno-exceptions -I../../_common -I../../. -I../../../tinySAK/src -I../../../tinyNET/src -I../../../tinyHTTP/include -I../../../tinyXCAP/include \
+ -I../../../tinySMS/include -I../../../tinySDP/include -I../../../tinyMEDIA/include -I../../../tinyMSRP/include -I../../../tinyDAV/include -I../../../tinySIP/include
+
+# Because of the static build, you need all librarires
+THIRDPARTIES_LIB := ../../../thirdparties/android/lib
+THIRDPARTIES_MARCH_LIB := ../../../thirdparties/android/lib/$(MARCH)
+
+FFMPEG_LDFLAGS := -lavutil -lswscale -lavcore -lavcodec -lx264 -ltheora -logg
+SPEEX_LDFLAGS := -lspeexdsp -lspeex
+OPENCORE_ARM_LDFLAGS := -lopencore-amrnb
+BV16_LDFLAGS := -lbv16
+ILBC_LDFLAGS := -liLBC
+LIBGSM_LDFLAGS := -lgsm
+
+ifeq ($(G729), yes)
+ G729_LDFLAGS := -lg729b_$(MARCH)
+
+ # Reset all other ITU CODECS
+ OPENCORE_ARM_LDFLAGS :=
+ BV16_LDFLAGS :=
+else
+ G729_LDFLAGS :=
+endif
+
+LDFLAGS := $(LDFLAGS_LIB) -L$(THIRDPARTIES_LIB) -L$(THIRDPARTIES_MARCH_LIB) $(FFMPEG_LDFLAGS) $(SPEEX_LDFLAGS) $(OPENCORE_ARM_LDFLAGS) $(BV16_LDFLAGS) $(ILBC_LDFLAGS) $(LIBGSM_LDFLAGS) $(G729_LDFLAGS)\
+ -Wl,-Bdynamic -lm -lstdc++ -lgcc -llog \
+ -Wl,-Bstatic -ltinySAK_$(MARCH) -ltinyHTTP_$(MARCH) -ltinyXCAP_$(MARCH) -ltinyIPSec_$(MARCH) -ltinySIGCOMP_$(MARCH) -ltinySMS_$(MARCH) -ltinyNET_$(MARCH) -ltinySDP_$(MARCH) -ltinyRTP_$(MARCH) -ltinyMEDIA_$(MARCH) -ltinyMSRP_$(MARCH) -ltinyDAV_$(MARCH) -ltinySIP_$(MARCH)
+
+
+all: $(APP)
+
+OBJS = tinyWRAP_wrap.o\
+ ../../_common/ActionConfig.o \
+ ../../_common/DDebug.o \
+ ../../_common/MediaContent.o \
+ ../../_common/MediaSessionMgr.o \
+ ../../_common/Msrp.o \
+ ../../_common/ProxyConsumer.o \
+ ../../_common/ProxyPluginMgr.o \
+ ../../_common/ProxyProducer.o \
+ ../../_common/SafeObject.o \
+ ../../_common/SipCallback.o \
+ ../../_common/SipEvent.o \
+ ../../_common/SipMessage.o \
+ ../../_common/SipSession.o \
+ ../../_common/SipStack.o \
+ ../../_common/SipUri.o \
+ ../../_common/SMSEncoder.o \
+ ../../_common/Xcap.o
+
+
+$(APP): $(OBJS)
+ifeq ($(EXT), a)
+ $(AR) rcs $@ $^
+else
+ $(CC) $(LDFLAGS) -o $@ $^
+endif
+
+%.o: %.cxx
+ $(CPP) -c $(INCLUDE) $(CFLAGS) $< -o $@
+
+install: $(APP)
+ $(ANDROID_SDK_ROOT)/tools/adb remount
+ $(ANDROID_SDK_ROOT)/tools/adb push $(APP) $(LIB_DIR)/$(APP)
+ $(ANDROID_SDK_ROOT)/tools/adb shell chmod 777 $(LIB_DIR)/$(APP)
+
+shell:
+ $(ANDROID_SDK_ROOT)/tools/adb shell
+
+run:
+ $(ANDROID_SDK_ROOT)/tools/adb shell $(LIB_DIR)/$(APP)
+
+clean:
+ @rm -f $(OBJS) $(APP) \ No newline at end of file
OpenPOWER on IntegriCloud