diff options
author | Henrik Nord <[email protected]> | 2014-03-21 16:39:02 +0100 |
---|---|---|
committer | Henrik Nord <[email protected]> | 2014-03-21 16:39:05 +0100 |
commit | a4030a89eb9a22d250dba2793f274f8731126ea8 (patch) | |
tree | 620592b3560f98be67f71f70fd5596cc110ecd70 /HOWTO/INSTALL-ANDROID.md | |
parent | c9da6c2f06efa410462299a20e10206843082ac8 (diff) | |
parent | f43a1dc55d42de3097f75ca65baead9a2ff05c78 (diff) | |
download | otp-a4030a89eb9a22d250dba2793f274f8731126ea8.tar.gz otp-a4030a89eb9a22d250dba2793f274f8731126ea8.tar.bz2 otp-a4030a89eb9a22d250dba2793f274f8731126ea8.zip |
Merge branch 'fogfish/embedded-arm-android'
* fogfish/embedded-arm-android:
Raspberry PI / Android a minimal cross-compile configuration
OTP-11805
Diffstat (limited to 'HOWTO/INSTALL-ANDROID.md')
-rw-r--r-- | HOWTO/INSTALL-ANDROID.md | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/HOWTO/INSTALL-ANDROID.md b/HOWTO/INSTALL-ANDROID.md new file mode 100644 index 0000000000..31698d4ce3 --- /dev/null +++ b/HOWTO/INSTALL-ANDROID.md @@ -0,0 +1,52 @@ +Cross Compiling Erlang/OTP - ANDROID +==================================== + +Introduction +------------ + +This document describes how to cross compile Erlang OTP to Android/Rasberry Pi platforms. + +### Download and Install Android NDK ### + +https://developer.android.com/tools/sdk/ndk/index.html + +### Define System Variables ### + +export NDK_ROOT=/usr/local/android +export NDK_PLAT=android-9 +export PATH=$NDK_ROOT/toolchains/arm-linux-androideabi-4.8/prebuilt/darwin-x86_64/bin:$PATH + +### Configure OTP ### + +./otp_build configure \ + --xcomp-conf=./xcomp/erl-xcomp-arm-android.conf \ + --without-ssl + +### Compile OTP ### + +make noboot [-j4] + +### Make Release ### + +./otp_build release -a /usr/local/otp_R16B03_arm + +### Target Deployment ### + +Make a tarball out of /usr/local/otp_R16B03_arm and copy it to target device +(e.g. Raspberry Pi). Extract it and install + +./Install /usr/local/otp_R16B03_arm + +Android SDK (adb tool) is used to deploy OTP/Erlang to target device for +evaluation purpose only. + +adb push /usr/local/otp_R16B03_arm /mnt/sdcard/otp_R16B03_arm +adb shell + +### Known Issues ### + + * native inet:gethostbyname/1 return {error, nxdomain} on Raspberry PI. Use dns resolver to by-pass the issue (see http://www.erlang.org/doc/apps/erts/inet_cfg.html) + +### References ### + + The port derives some solutions from https://code.google.com/p/erlang4android/ |