Boost logo

Boost :

Subject: Re: [boost] Boost Support for Android and iOS
From: Eoin O'Callaghan (eoinocal_at_[hidden])
Date: 2013-01-24 13:58:21


If it helps anyone - I've had great success on Windows by simply
manually applying the
https://github.com/MysticTreeGames/Boost-for-Android patches and
compiling with Boost.Build using this user-config.jam:

androidPlatform = windows ;
gccVer = 4.6 ;
ndkRoot = C:/Craftwork/Android/android-ndk-r8b ;

using gcc : android.arm.4.6 :
$(ndkRoot)/toolchains/arm-linux-androideabi-$(gccVer)/prebuilt/$(androidPlatform)/bin/arm-linux-androideabi-g++
:
<compileflags>--sysroot=$(ndkRoot)/platforms/android-8/arch-arm
<compileflags>-marm
<compileflags>-Os
<compileflags>-fno-strict-aliasing
<compileflags>-fexceptions
<compileflags>-fpic
<compileflags>-fstack-protector
<compileflags>-frtti
<compileflags>-fno-short-enums
<compileflags>-O2
<compileflags>-DNDEBUG
<compileflags>-g
<compileflags>-lstdc++
<compileflags>-std=gnu++0x
<compileflags>-I"$(ndkRoot)/platforms/android-8/arch-arm"
<compileflags>-I"$(ndkRoot)/sources/cxx-stl/gnu-libstdc++/$(gccVer)/include/"
<compileflags>-I"$(ndkRoot)/sources/cxx-stl/gnu-libstdc++/$(gccVer)/libs/armeabi/include/"
<compileflags>-DGLIBC
<compileflags>-D_GLIBCPP_USE_WCHAR_T
<compileflags>-D_GLIBCXX__PTHREADS
<compileflags>-DANDROID
<compileflags>-D_LITTLE_ENDIAN
<archiver>$(ndkRoot)/toolchains/arm-linux-androideabi-$(gccVer)/prebuilt/$(androidPlatform)/bin/arm-linux-androideabi-ar
<ranlib>$(ndkRoot)/toolchains/arm-linux-androideabi-$(gccVer)/prebuilt/$(androidPlatform)/bin/arm-linux-androideabi-ranlib
;

Command-line:

bjam --with-thread threadapi=pthread toolset=gcc-android.arm.4.6
link=static runtime-link=static target-os=linux --stagedir=android-arm


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk