Simplify building with the Android NDK.
authorJonathan Pryor <jonpryor@vt.edu>
Fri, 3 Jun 2011 20:42:38 +0000 (16:42 -0400)
committerJonathan Pryor <jonpryor@vt.edu>
Fri, 3 Jun 2011 20:42:38 +0000 (16:42 -0400)
commit46f61e7240a8e2d0a0625b9990c8926efeafde89
treecfdf67acd33619b327592f55317c7b2ccb87ed50
parent0d0930f3a4c2730142e03c34784d76c1daa62d88
Simplify building with the Android NDK.

Check --host against *-*-linux-android* for Android-specific configure fixes,
and improve **/Makefile.am to simplify Android support:

./configure \
--build=`./config.guess` \
--host=armv5-linux-androideabi \
--target=armv5-linux-androideabi \
--enable-nls=no --with-mcs-docs=no --enable-mcs-build=no \
CC="/path/to/ndk/arm-linux-androideabi-gcc --sysroot=/path/to/sysroot" \
AR="..." AS="..." CPP="..." CXX="..." LD="..." RANLIB="..." STRIP="..."
CFLAGS="-DARM_FPU_NONE=1" CXXFLAGS="-DARM_FPU_NONE=1"

See also Android NDK docs/STANDALONE-TOOLCHAIN.html.

The Android NDK/bionic is "interesting", in that it's lacking header files and
macros normally present on Linux which otherwise break the build (e.g. no
<link.h> which breaks Boehm support).  Using --host with an android target
works around the known issues, simplifying the building of libmonosgen-2.0.so
with the Android NDK toolchain.
configure.in
eglib/configure.ac
eglib/src/Makefile.am
mono/dis/Makefile.am
mono/metadata/Makefile.am
mono/mini/Makefile.am