glaznev@webrtc.org | 4b407aa | 2014-12-04 22:42:59 +0000 | [diff] [blame^] | 1 | This directory contains an example Android client for https://3-dot-apprtc.appspot.com |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 2 | |
| 3 | Prerequisites: |
fischman@webrtc.org | 43a1395 | 2014-05-28 17:29:09 +0000 | [diff] [blame] | 4 | - "Android Specific Steps" on http://www.webrtc.org/reference/getting-started |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 5 | - Set up webrtc-related GYP variables: |
| 6 | export GYP_DEFINES="build_with_libjingle=1 build_with_chromium=0 libjingle_java=1 $GYP_DEFINES" |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 7 | To cause WEBRTC_LOGGING to emit to Android's logcat, add enable_tracing=1 to |
| 8 | the $GYP_DEFINES above. |
| 9 | - When targeting both desktop & android, make sure to use a different output_dir |
| 10 | value in $GYP_GENERATOR_FLAGS or you'll likely end up with mismatched ARM & |
| 11 | x86 output artifacts. If you use an output_dir other than out/ make sure to |
| 12 | modify the command-lines below appropriately. |
| 13 | - Finally, run "gclient runhooks" to generate Android-targeting .ninja files. |
| 14 | |
| 15 | Example of building & using the app: |
| 16 | |
| 17 | cd <path/to/libjingle>/trunk |
| 18 | ninja -C out/Debug AppRTCDemo |
| 19 | adb install -r out/Debug/AppRTCDemo-debug.apk |
| 20 | |
glaznev@webrtc.org | 4b407aa | 2014-12-04 22:42:59 +0000 | [diff] [blame^] | 21 | In desktop chrome, navigate to https://3-dot-apprtc.appspot.com and note the r=<NNN> room |
| 22 | this redirects to or navigate directly to https://3-dot-apprtc.appspot.com/room/<NNN> with |
| 23 | your own room number. Launch AppRTC on the device and add same <NNN> into the room name list. |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 24 | |
glaznev@webrtc.org | 4b407aa | 2014-12-04 22:42:59 +0000 | [diff] [blame^] | 25 | You can also run application from a command line to connect to the first room in a list: |
| 26 | adb shell am start -n org.appspot.apprtc/.ConnectActivity -a android.intent.action.VIEW |
| 27 | This should result in the app launching on Android and connecting to the 3-dot-apprtc |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 28 | page displayed in the desktop browser. |
glaznev@webrtc.org | 4b407aa | 2014-12-04 22:42:59 +0000 | [diff] [blame^] | 29 | To run loopback test execute following command: |
| 30 | adb shell am start -n org.appspot.apprtc/.ConnectActivity -a android.intent.action.VIEW --ez "org.appspot.apprtc.LOOPBACK" true |
henrike@webrtc.org | 28e2075 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 31 | |