To build the java code you only need Eclipse and Android SDK.
IMSDroid contains only one native library (tinyWRAP.so) written in C++ as a wrapper for doubango project. The JNI files are generated using SWIG.
To build tinyWRAP you have to build all doubango's libraries (ANSI-C).
tinyWRAP depends on:
The project also depends on FFmpeg, x264, opencore-amr, libogg, libvorbis, libtheora, iLBC, Speex, ... but you don't need to rebuild these libraries as they are already part of doubango ($(DOUBANGO_HOME)/thirdparties/android/lib).
svn checkout http://doubango.googlecode.com/svn/trunk/ doubango-read-only
export PATH=$ANDROID_NDK_ROOT\build\prebuilt\$(HOST)\arm-eabi-4.2.1\bin:$PATH
where $HOST is equal to darwin-x86 on MAC OS X, windows on Windows XP/Vista/7 and linux-x86 on Unix-like systems. We assume that $(ANDROID_GCC_VER) is equal to 4.2.1.
export CFLAGS="–Os –DDEBUG_LEVEL=DEBUG_LEVEL_ERROR"
You can off course set any valid GCC $(CFLAGS) flags.
Example of doubango's specific flags:
cd $(DOUBANGO_HOME)/android-projects
../bindings/java/android/buildAll.sh # For neon optimizations #../bindings/java/android/buildAll.sh NEON=yes
You can add NEON=yes to enable neon optimization for armv7-a processors. You MUST use at least NDK r4b.
The binaries will be generated under $(DOUBANGO_HOME)/android-projects/output. The shared libraries will be named libtinyWRAP_armv7-a.so if built with neon optimizations. Otherwise it will be named libtinyWRAP_armv5te.so. Rename the library as libtinyWRAP.so and copy it to imsdroid\libs\$(ABI) where ABI is equal to armeabi for the ARMv5te version or armeabi-v7a for ARMv7-a.
Starting IMSDroid revision 311 and doubango revision 498 we fully support G.729 annex A and B (CNG and VAD).
G.729 should only be used for experimental purpose. G.729 includes patents from several companies and is licensed by Sipro Lab Telecom.
Sipro Lab Telecom is the authorized Intellectual Property Licensing Administrator for G.729 technology and patent pool.
In a number of countries, the use of G.729 may require a license fee and/or royalty fee.
Because of the licensing issue the application is not built with G.729.
To build libtinyWRAP.so with G.729AB support:
cd $(DOUBANGO_HOME)
svn checkout http://g729.googlecode.com/svn/trunk/ /cygdrive/c/tmp/g729b
cp -f /cygdrive/c/tmp/g729b/* $(DOUBANGO_HOME)/g729b
cd $(DOUBANGO_HOME)/android-projects make PROJECT=g729b BT=static install #For cleanup #make PROJECT=g729b BT=static clean
../bindings/java/android/buildAll.sh G729=yes # For neon optimizations #../bindings/java/android/buildAll.sh G729=yes NEON=yes
You can add NEON=yes to enable neon optimization for armv7-a processors. You MUST use at least NDK r4b.
The binaries will be generated under $(DOUBANGO_HOME)/android-projects/output. The shared libraries will be named libtinyWRAP_armv7-a.so if built with neon optimizations. Otherwise it will be named libtinyWRAP_armv5te.so. Rename the library as libtinyWRAP.so and copy it to imsdroid\libs\$(ABI) where ABI is equal to armeabi for the ARMv5te version or armeabi-v7a for ARMv7-a.
Et voilà