Build Linphone Android for i.MX6

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Build Linphone Android for i.MX6

Build Linphone Android for i.MX6

Linphone is an internet phone or Voice Over IP phone (VoIP).

  • With Linphone you can communicate freely with people over the internet, with voice, video, and text instant messaging.
  • Linphone makes use of the SIP protocol, an open standard for internet telephony. You can use Linphone with any SIP VoIP operator, including our free SIP audio/video service.
  • Linphone is free software (or open-source), you can download and redistribute it freely.
  • Linphone is available for desktop computers: Linux, Windows, Mac OSX, and for mobile phones: Android, iPhone, Blackberry.

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.


Labels (4)
Comments

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

Is there the Linphone for Android using the CPU's hardware encoder?

If I use it on imx53 or imx6, it will use VPU?

It will not use the VPU. You will have to write a plugin which uses the hardware encoder. You could try using gstreamer appsrc plugin and combining that with a new mediastreamer2 plugin

Hi,

Do anybody have idea regarding whether we can use i.MX6 for designing Analog telephone adaptors? What kind of SW application we need to implement on i.MX6D?

%3CLINGO-SUB%20id%3D%22lingo-sub-1114630%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EBuild%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114630%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%3CSTRONG%3ELinphone%20is%20an%20internet%20phone%20or%20Voice%20Over%20IP%20phone%20(VoIP).%3C%2FSTRONG%3E%3C%2FP%3E%3CUL%3E%3CLI%3EWith%20Linphone%20you%20can%20communicate%20freely%20with%20people%20over%20the%20internet%2C%20%3CSTRONG%3Ewith%20voice%2C%20video%2C%20and%20text%20instant%20messaging%3C%2FSTRONG%3E.%3C%2FLI%3E%3CLI%3ELinphone%20makes%20use%20of%20the%20%3CSTRONG%3E%20%3CA%20href%3D%22http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FSession_Initiation_Protocol%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%20target%3D%22_blank%22%3ESIP%20protocol%3C%2FA%3E%2C%20an%20open%20standard%20for%20internet%20telephony%3C%2FSTRONG%3E.%20You%20can%20use%20Linphone%20%3CSTRONG%3Ewith%20any%20SIP%20VoIP%20operator%3C%2FSTRONG%3E%2C%20including%20our%20%3CA%20href%3D%22http%3A%2F%2Fwww.linphone.org%2Feng%2Flinphone%2Fregister-a-linphone-account.html%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%20target%3D%22_blank%22%3Efree%20SIP%20audio%2Fvideo%20service%3C%2FA%3E.%3C%2FLI%3E%3CLI%3ELinphone%20is%20%3CSTRONG%3Efree%20software%3C%2FSTRONG%3E%20(or%20open-source)%2C%20%3CSTRONG%3Eyou%20can%20download%20and%20redistribute%20it%20freely%3C%2FSTRONG%3E.%3C%2FLI%3E%3CLI%3ELinphone%20is%20available%20for%20desktop%20computers%3A%20Linux%2C%20Windows%2C%20Mac%20OSX%2C%20and%20for%20mobile%20phones%3A%20Android%2C%20iPhone%2C%20Blackberry.%3C%2FLI%3E%3C%2FUL%3E%3CP%3E%3C%2FP%3E%3CP%3ELinphone-android%20is%20a%20good%20example%20to%20show%20the%20integration%20of%20Java%20code%20based%20on%20Android%20SDK%20with%20native%20CODEC%2C%20network%20protocols.%20Not%20like%20XBMC-Android%20that%20is%20almost%20total%20c%2B%2B%2Fc%20project.%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3EPerform%20the%20following%20steps%20to%20build%20a%20linphone-android%20project%3A%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E1.%20git%20clone%20git%3A%2F%2Fgit.linphone.org%2Flinphone-android.git%20--recursive%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22mce_paste_marker%22%3E%3CBR%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22mce_paste_marker%22%3E2.%20%3C%2FSPAN%3Esudo%20apt-get%20install%20autoconf%20automake%20libtool%20pkg-config%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E3.%20%22cd%22%20to%20the%20root%20of%20%22git%20clone%22%20%3A%20cd%20%2Fhome%2Fuser%2Flinphne-android%20%2F%2F%20wherver%20git'ed%20linphone-android%20is%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E4.%20export%20PATH%3D%2Fhome%2Fuser%2Fandroid-ndk%3A%24PATH%20%2F%2Fwherever%20your%20android-ndk%2C%20android-sdk%20tools%2C%20and%20platform-tools%2C%20and%20ANT%20are%20stored%20in.%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20For%20example%20on%20my%20PC.%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20export%20PATH%3D%2Fhome%2Falanz%2Fandroid-ndk-r8d%3A%2Fhome%2Falanz%2Fandroid-sdk-linux%2Ftools%3A%2Fhome%2Falanz%2Fandroid-sdk-linux%2Fplatform-%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20tools%3A%2Fhome%2Falanz%2Fbin%2Fapache-ant-1.8.4%2Fbin%3A%24PATH%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20Note%3A%20PATH%20contains%20the%20ndk%2C%20sdk%2C%20and%20ant.%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E5.%20Make%20sure%20the%20network%20is%20working%2C%20then%20execute%20%22.%2Fprepare_sources.sh%22%20at%20the%20linphone-android%20root%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E6.%20Then%2C%20execute%20%22%2Fhome%2Falanz%2Fandroid-ndk-r8d%2Fndk-build%22%2C%20it%20will%20take%20a%20while%20to%20be%20finished%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E7.%20Modify%20Makefile%20as%20following%20example%2C%20modify%20it%20accordingly.%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20NDK_PATH%3D%2Fhome%2Falanz%2Fandroid-ndk-r8d%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20SDK_PATH%3D%2Fhome%2Falanz%2Fandroid-sdk-linux%2Ftools%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20SDK_PLATFORM_TOOLS_PATH%3D%2Fhome%2Falanz%2Fandroid-sdk-linux%2Fplatform-tools%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20.....................%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20generate-libs%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20%24(NDK_PATH)%2Fndk-build%20.......%20(remove%20-j%24(NUMCPUS)%20by%20the%20end%20of%20this%20command%20line)%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E8.%20execute%20%22make%22%2C%20after%20finish%2C%20the%20apk%20file%20can%20be%20found%20under%20bin%2F%20subdirectory.%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22mce_paste_marker%22%3E%3CBR%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1114630%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CLINGO-LABEL%3EAndroid%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Ei.MX53%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Ei.MX6DL%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Ei.MX6Quad%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1114635%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20Build%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114635%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3EDo%20anybody%20have%20idea%20regarding%20whether%20we%20can%20use%20i.MX6%20for%20designing%20Analog%20telephone%20adaptors%3F%20What%20kind%20of%20SW%20application%20we%20need%20to%20implement%20on%20i.MX6D%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1114634%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20Build%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114634%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EIt%20will%20not%20use%20the%20VPU.%20You%20will%20have%20to%20write%20a%20plugin%20which%20uses%20the%20hardware%20encoder.%20You%20could%20try%20using%20gstreamer%20appsrc%20plugin%20and%20combining%20that%20with%20a%20new%20mediastreamer2%20plugin%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1114633%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20Build%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114633%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EIs%20there%20the%20Linphone%20for%20Android%20using%20the%20CPU's%20hardware%20encoder%3F%3C%2FP%3E%3CP%3EIf%20I%20use%20it%20on%20imx53%20or%20imx6%2C%20it%20will%20use%20VPU%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1114632%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20Build%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114632%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EThere%20is%20no%20%3CSPAN%20style%3D%22color%3A%20%233d3d3d%3B%20font-family%3A%20'Helvetica%20Neue'%2C%20Helvetica%2C%20Arial%2C%20'Lucida%20Grande'%2C%20sans-serif%3B%20font-size%3A%2012.800000190734863px%3B%22%3Eprepare_sources.sh%3C%2FSPAN%3E%20file%20in%20the%20latest%20linphone-android%20sources.%20I%20was%20able%20to%20build%20linphone%20according%20to%20the%20README%20directions%20of%20the%20linphone-android%20git%20sources%20and%20run%20it%20on%20an%20android%20phone%20and%20it%20works%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1114631%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20Build%20Linphone%20Android%20for%20i.MX6%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1114631%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%20thanks%20for%20your%20help%20but%20i%20am%20getting%20below%20error%20in%205th%20step%2C%20while%20executing%20%3CSPAN%20style%3D%22font-family%3A%20'Helvetica%20Neue'%2C%20Helvetica%2C%20Arial%2C%20'Lucida%20Grande'%2C%20sans-serif%3B%20background-color%3A%20%23ffffff%3B%22%3E%22.%2Fprepare_sources.sh%22%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3C%2FP%3E%3CP%3Ecp%20.%2Fpatch_pic.diff%20SILK_SDK_SRC_v1.0.9%2FSILK_SDK_SRC_ARM_v1.0.9%3C%2FP%3E%3CP%3Ecd%20SILK_SDK_SRC_v1.0.9%2FSILK_SDK_SRC_ARM_v1.0.9%20%26amp%3B%26amp%3B%20%2Fusr%2Fbin%2Fpatch%20-p0%20%26lt%3B%20patch_pic.diff%3C%2FP%3E%3CP%3Epatching%20file%20Makefile%3C%2FP%3E%3CP%3EHunk%20%231%20FAILED%20at%2026.%3C%2FP%3E%3CP%3E1%20out%20of%201%20hunk%20FAILED%20--%20saving%20rejects%20to%20file%20Makefile.rej%3C%2FP%3E%3CP%3EMakefile%3A420%3A%20recipe%20for%20target%20%60SILK_SDK_SRC_v1.0.9%2FSILK_SDK_SRC_ARM_v1.0.9'%20failed%3C%2FP%3E%3CP%3Emake%3A%20***%20%5BSILK_SDK_SRC_v1.0.9%2FSILK_SDK_SRC_ARM_v1.0.9%5D%20Error%201%3C%2FP%3E%3CP%3ESILK%20audio%20plugin%20prepare%20state%20failed.%3C%2FP%3E%3CP%3E.%2Fprepare_sources.sh%3A%20line%2041%3A%20xxd%3A%20command%20not%20found%3C%2FP%3E%3CP%3E.%2Fprepare_sources.sh%3A%20line%2047%3A%20xxd%3A%20command%20not%20found%3C%2FP%3E%3CP%3E%3C%2FP%3E%3CP%3E%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3C%2FP%3E%3CP%3EMain%20problem%20is%2C%20when%20with%20these%20errors%2C%20i%20complete%20all%20steps%20and%20move%20ahead%20and%20import%20code%20in%20eclipse%2C%20run%20then%20i%20get%20java.lang.NoClassDefFoundException%20in%20GCMRegister%20class%20if%20i%20comment%20this%20code%20then%20same%20error%20for%20LinphoneActivity.java.%20please%20guide%20how%20i%20can%20get%20rid%20of%20this%20error%20and%20successfully%20run%20and%20test%20this%20code.%20Thanks%20in%20Advance.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22mce_paste_marker%22%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
No ratings
Version history
Last update:
‎02-27-2013 08:58 PM
Updated by: