| 72 | == Building and running pjsua2 sample application == #pjsua2 |
| 73 | |
| 74 | Another sample application, which is based on [https://trac.pjsip.org/repos/ticket/1519 pjsua2 high-level API] with SWIG binding, is located under {{{pjsip-apps/src/swig/java/android}}}. It is not built by default, and you need [http://www.swig.org/download.html SWIG] to build it. |
| 75 | |
| 76 | Follow these steps to build pjsua2 sample application: |
| 77 | 1. Make sure SWIG is in the build environment PATH. |
| 78 | 1. Run {{{make}}} from directory {{{$PJDIR/pjsip-apps/src/swig}}}, note that the Android NDK root should be in the PATH, e.g: |
| 79 | {{{ |
| 80 | $ cd /path/to/your/pjsip/dir |
| 81 | $ cd pjsip-apps/src/swig |
| 82 | $ make |
| 83 | }}} |
| 84 | 1. Create Android project from pjsua. In Eclipse: |
| 85 | a. From menu: '''File''' --> '''New''' --> '''Project''' |
| 86 | a. Select '''Android Project from Existing Code''', press '''Next''' |
| 87 | a. In ''Root Directory'', put the location of '''pjsua2''' source code (i.e. {{{$PJDIR/pjsip-apps/src/swig/java/android}}}) and press '''Finish''' |
| 88 | 1. You may need to select different Android SDK than what is configured in pjsua2. You can do this from the project's '''Properties'''. |
| 89 | 1. Run it. |
| 90 | |
| 91 | |