Linphone is an internet phone or Voice Over IP phone (VoIP).
Linphone-android is a good example to show the integration of Java code based on Android SDK with native CODEC, network protocols. Not like XBMC-Android that is almost total c++/c project.
Perform the following steps to build a linphone-android project:
1. git clone git://git.linphone.org/linphone-android.git --recursive
2. sudo apt-get install autoconf automake libtool pkg-config
3. "cd" to the root of "git clone" : cd /home/user/linphne-android // wherver git'ed linphone-android is
4. export PATH=/home/user/android-ndk:$PATH //wherever your android-ndk, android-sdk tools, and platform-tools, and ANT are stored in.
For example on my PC.
export PATH=/home/alanz/android-ndk-r8d:/home/alanz/android-sdk-linux/tools:/home/alanz/android-sdk-linux/platform- tools:/home/alanz/bin/apache-ant-1.8.4/bin:$PATH
Note: PATH contains the ndk, sdk, and ant.
5. Make sure the network is working, then execute "./prepare_sources.sh" at the linphone-android root
6. Then, execute "/home/alanz/android-ndk-r8d/ndk-build", it will take a while to be finished
7. Modify Makefile as following example, modify it accordingly.
NDK_PATH=/home/alanz/android-ndk-r8d
SDK_PATH=/home/alanz/android-sdk-linux/tools
SDK_PLATFORM_TOOLS_PATH=/home/alanz/android-sdk-linux/platform-tools
.....................
generate-libs:
$(NDK_PATH)/ndk-build ....... (remove -j$(NUMCPUS) by the end of this command line)
8. execute "make", after finish, the apk file can be found under bin/ subdirectory.
Hi thanks for your help but i am getting below error in 5th step, while executing "./prepare_sources.sh"
===========================================================================
cp ./patch_pic.diff SILK_SDK_SRC_v1.0.9/SILK_SDK_SRC_ARM_v1.0.9
cd SILK_SDK_SRC_v1.0.9/SILK_SDK_SRC_ARM_v1.0.9 && /usr/bin/patch -p0 < patch_pic.diff
patching file Makefile
Hunk #1 FAILED at 26.
1 out of 1 hunk FAILED -- saving rejects to file Makefile.rej
Makefile:420: recipe for target `SILK_SDK_SRC_v1.0.9/SILK_SDK_SRC_ARM_v1.0.9' failed
make: *** [SILK_SDK_SRC_v1.0.9/SILK_SDK_SRC_ARM_v1.0.9] Error 1
SILK audio plugin prepare state failed.
./prepare_sources.sh: line 41: xxd: command not found
./prepare_sources.sh: line 47: xxd: command not found
=====================================================================
Main problem is, when with these errors, i complete all steps and move ahead and import code in eclipse, run then i get java.lang.NoClassDefFoundException in GCMRegister class if i comment this code then same error for LinphoneActivity.java. please guide how i can get rid of this error and successfully run and test this code. Thanks in Advance.
There is no prepare_sources.sh file in the latest linphone-android sources. I was able to build linphone according to the README directions of the linphone-android git sources and run it on an android phone and it works