sfl android | 42fcf7a | 2012-08-06 15:45:32 -0400 | [diff] [blame] | 1 | This repository is meant for the porting of SFLphone to Android. |
| 2 | |
| 3 | |
| 4 | To build SFLphone and all its dependencies, make sure that Android's NDK and SDK |
| 5 | are properly installed on your system. |
| 6 | |
| 7 | You have also to make sure that the following environment variables are defined: |
| 8 | |
Tristan Matthews | d8aa432 | 2013-07-17 10:51:54 -0400 | [diff] [blame] | 9 | export ANDROID_NDK=$HOME/path/to/android-ndk-r*b |
| 10 | export ANDROID_SDK=$HOME/path/to/android-sdk-linux |
sfl android | 42fcf7a | 2012-08-06 15:45:32 -0400 | [diff] [blame] | 11 | |
| 12 | The path to the required Android's build executable must be also specified: |
| 13 | |
| 14 | export PATH=$PATH:$ANDROID_NDK |
Emeric Vigier | 9701e03 | 2012-09-12 12:38:01 -0400 | [diff] [blame] | 15 | |
| 16 | BUILD |
| 17 | ----- |
Emeric Vigier | cca7f56 | 2012-09-20 14:22:30 -0400 | [diff] [blame] | 18 | install swig-2.0.6 or later and python-2.7 or later on your system |
Emeric Vigier | 9701e03 | 2012-09-12 12:38:01 -0400 | [diff] [blame] | 19 | |
| 20 | $ cd sflphone-android |
| 21 | |
| 22 | Check that following files are executable: |
| 23 | jni/sflphone/daemon/src/JavaJNI2CJNI_Load.py |
| 24 | make-swig.sh |
| 25 | |
Adrien Béraud | 432f067 | 2013-02-27 17:06:36 -0500 | [diff] [blame] | 26 | Compile pjsip-android |
Alexandre Lision | 7c6f4a6 | 2013-09-05 13:27:01 -0400 | [diff] [blame] | 27 | $ pushd jni/pjproject-android/ |
Alexandre Lision | 261eb33 | 2013-09-19 17:02:31 -0400 | [diff] [blame] | 28 | $ ./configure-android |
alision | f4571d9 | 2013-07-04 17:11:35 -0400 | [diff] [blame] | 29 | |
alision | f76de3b | 2013-04-16 15:35:22 -0400 | [diff] [blame] | 30 | $ make dep && make |
| 31 | $ popd |
| 32 | |
| 33 | |
| 34 | Generate dbus interface |
Alexandre Lision | 7c6f4a6 | 2013-09-05 13:27:01 -0400 | [diff] [blame] | 35 | $ ./make-swig.sh |
| 36 | |
| 37 | Compile libsndfile-1.0.25 |
| 38 | $ pushd jni/libsndfile-1.0.25/ |
| 39 | $ ./configure --disable-alsa --disable-external-libs |
| 40 | $ popd |
alision | f76de3b | 2013-04-16 15:35:22 -0400 | [diff] [blame] | 41 | |
Adrien Béraud | 432f067 | 2013-02-27 17:06:36 -0500 | [diff] [blame] | 42 | |
Emeric Vigier | c30b71d | 2012-09-12 14:51:47 -0400 | [diff] [blame] | 43 | $ ndk-build -j4 |
Emeric Vigier | 9701e03 | 2012-09-12 12:38:01 -0400 | [diff] [blame] | 44 | |
Emeric Vigier | c30b71d | 2012-09-12 14:51:47 -0400 | [diff] [blame] | 45 | Check that no errors occurred. In particular, following files should have been generated by make-swig.sh: |
Emeric Vigier | 9701e03 | 2012-09-12 12:38:01 -0400 | [diff] [blame] | 46 | sflphoneservice_loader.c |
| 47 | callmanager_wrap.cpp |
| 48 | sflphoneservice.java |
| 49 | sflphoneserviceJNI.java |
| 50 | ManagerImpl.java |
| 51 | |
alision | f76de3b | 2013-04-16 15:35:22 -0400 | [diff] [blame] | 52 | |
| 53 | Add compatibility library to libs folder |
| 54 | $ cp $ANDROID_SDK/extras/android/support/v13/android-support-v13.jar ./libs/ |
| 55 | |
| 56 | |
Emeric Vigier | 9701e03 | 2012-09-12 12:38:01 -0400 | [diff] [blame] | 57 | Then build android project with your favorite JDK: eclipse or ant. |