Tagged: android

PJSIP for android installation on Mac OSX Mavericks

Hi all, 

I am trying to install PJSIP on Mac from many days but i got succeeded today. Here are the steps to be executed as they are not mentioned in website. 

Please have a look at the link 

http://trac.pjsip.org/repos/wiki/Getting-Started/Android 

This link is the starting point to get the source code and the instructions to make PJSIP  for android install. 

  • Do follow the sections Requirements, Build Preparation, Build PJSIP
  • In the section “Building and running PJSUA sample application” if we do the following steps, 
    $ cd /path/to/your/pjsip/dir
    $ cd pjsip-apps/src/pjsua/android
    $ ndk-build 
  •  
    Android NDK: WARNING:jni/Android.mk:pjsua: non-system libraries in linker flags: -    lpjsua-arm-unknown-linux-androideabi -lpjsip-ua-arm-unknown-linux-androideabi -lpjsip-simple-arm-unknown-linux-androideabi -lpjsip-arm-unknown-linux-androideabi -lpjmedia-codec-arm-unknown-linux-androideabi -lpjmedia-videodev-arm-unknown-linux-androideabi -lpjmedia-arm-unknown-linux-androideabi -lpjmedia-audiodev-arm-unknown-linux-androideabi -lpjmedia-arm-unknown-linux-androideabi -lpjnath-arm-unknown-linux-androideabi -lpjlib-util-arm-unknown-linux-androideabi -lresample-arm-unknown-linux-androideabi -lmilenage-arm-unknown-linux-androideabi -lsrtp-arm-unknown-linux-androideabi -lgsmcodec-arm-unknown-linux-androideabi -lspeex-arm-unknown-linux-androideabi -lilbccodec-arm-unknown-linux-androideabi -lg7221codec-arm-unknown-linux-androideabi -lpj-arm-unknown-linux-androideabi -lgcc -lgcc    
    This is likely to result in incorrect builds. Try using LOCAL_STATIC_LIBRARIES or LOCAL_SHARED_LIBRARIES instead to list the library dependencies of the    
    current module    
    Invoking SWIG...
    swig -c++ -o jni/pjsua_wrap.cpp -package org.pjsip.pjsua -outdir src/org/pjsip/pjsua -java jni/pjsua.i
    Compile++ thumb  : pjsua <= pjsua_wrap.cpp
    SharedLibrary  : libpjsua.so
    arm-linux-androideabi-g++: error: /home/hadi/Development/pjproject/pjsip-    apps/build/output/pjsua-arm-unknown-linux-androideabi/pjsua_app.o: No such file or directory
    arm-linux-androideabi-g++: error: /home/hadi/Development/pjproject/pjsip-apps/build/output/pjsua-arm-unknown-linux-androideabi/pjsua_app_cli.o: No such file or directory
    arm-linux-androideabi-g++: error: /home/hadi/Development/pjproject/pjsip-apps/build/output/pjsua-arm-unknown-linux-androideabi/pjsua_app_common.o: No such file or directory
    arm-linux-androideabi-g++: error: /home/hadi/Development/pjproject/pjsip-apps/build/output/pjsua-arm-unknown-linux-androideabi/pjsua_app_config.o: No such file or directory
    arm-linux-androideabi-g++: error: /home/hadi/Development/pjproject/pjsip-apps/build/output/pjsua-arm-unknown-linux-androideabi/pjsua_app_legacy.o: No such file or directory
    make: *** [obj/local/armeabi/libpjsua.so] Error 1
  • In order to avoid the above error , do perform the following command " cd pjsip-apps/build " && "make pjsua" 
  • after the successful execution, then perform ndk-build in /pjsip-apps/src/pjsua/android directory.
  • This will result in the following output.
  • Invoking SWIG…

    swig -c++ -o jni/pjsua_wrap.cpp -package org.pjsip.pjsua -outdir src/org/pjsip/pjsua -java jni/pjsua.i

    [armeabi] Compile++ thumb: pjsua <= pjsua_wrap.cpp

    [armeabi] SharedLibrary  : libpjsua.so

    [armeabi] Install        : libpjsua.so => libs/armeabi/libpjsua.so