Boost Support for Android and iOS

Hi, Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS 1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason? 2. Are there (at all) any known issues if we use boost libraries for networking and thread synchronization for Smartphone application development ? Will it be a good idea to use BOOST ASIO for the same? I found some articles to compile boost but it would be great if we have some official links. FYI are the links found https://github.com/MysticTreeGames/Boost-for-Android http://www.codexperiments.com/android/2011/05/tips-tricks-building-boost-wit... RDX

Hi, I've used several boost libraries on iOS without any problem. However, I consciously avoided using libraries that might have to work with the platform API to avoid any problem. I think only some platform, abstracting platform specific functionality, would need to provide additional platform support, not all boost libraries. Joel Lamotte

So is it okay to port libboost_system.a and boost asio headers on Android and iOS? Or there is requirement of providing additional platform support for Android? On Wed, Dec 26, 2012 at 6:44 PM, Klaim - Joël Lamotte <mjklaim@gmail.com>wrote:
Hi,
I've used several boost libraries on iOS without any problem. However, I consciously avoided using libraries that might have to work with the platform API to avoid any problem. I think only some platform, abstracting platform specific functionality, would need to provide additional platform support, not all boost libraries.
Joel Lamotte
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
-- Rohit Dhamija

Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS
1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason? At least, it would be difficult to run the regression tests on these
On 26.12.2012 16:59, rohit dhamija wrote: platforms. OTOH, the Windows CE platform seems to be supported. -- Sergey Cheban

On 26/12/12 13:59, rohit dhamija wrote:
Hi,
Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS
1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason?
2. Are there (at all) any known issues if we use boost libraries for networking and thread synchronization for Smartphone application development ? Will it be a good idea to use BOOST ASIO for the same?
There is no reason why it wouldn't work. If it doesn't work, file a bug.

On Wednesday, December 26, 2012 18:29:57 rohit dhamija wrote:
Hi,
Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS
1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason?
Boost works perfectly on Android. As there is a NDK (native development kit) with a quite decent gcc (4.6 something) you just need to configure boost build to use the right gcc. Although this all works, it requires a little bit of tinkering to get the settings right. But again, in principle, there is not a lot of difference in building Boost for Android or any other linux distribution.
2. Are there (at all) any known issues if we use boost libraries for networking and thread synchronization for Smartphone application development ? Will it be a good idea to use BOOST ASIO for the same?
It is perfectly fine to use Boost.Thread or Boost.Asio. They work perfectly fine on ARM devices. There is even support for the more platform specific hackeries like boost.atomic and boost.context.
I found some articles to compile boost but it would be great if we have some official links.
FYI are the links found https://github.com/MysticTreeGames/Boost-for-Android http://www.codexperiments.com/android/2011/05/tips-tricks-building-boost-wit h-ndk-r5/
Building boost with the Android NDK is even simpler than with boost.build directly. I compiled a bunch of Android build scripts, which can be found here: https://github.com/STEllAR-GROUP/HPXAndroid/tree/master/modules Look for the boost_${module} for various boost libraries. This is not a complete list. Only what i needed. Also, might need some love for 1.53. All the different libraries didn't need any special android treatment (modulo some minor bugs where the compiler didn't agree with other gcc versions)
RDX
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

On 27.12.2012. 12:22, Thomas Heller wrote:
Boost works perfectly on Android. As there is a NDK (native development kit) with a quite decent gcc (4.6 something) you just need to configure boost build to use the right gcc. Although this all works, it requires a little bit of tinkering to get the settings right. But again, in principle, there is not a lot of difference in building Boost for Android or any other linux distribution.
I/"we" use only the header-only parts of Boost so I can only speak about that part of the "Android+Boost" experience. While it does mostly work I can't agree that it "works perfectly on Android". After all you posted a link to your own scripts that help with the "Android+Boost" experience. A Trac search for "android" doesn't show up empty: svn.boost.org/trac/boost/search?q=android. and the existence of https://github.com/MysticTreeGames/Boost-for-Android https://github.com/mevansam/cmoss/tree/master/build-droid http://www.mfoot.com/2011/12/building-boost-1-47-for-android-using-cmake-and... http://www.codexperiments.com/android/2011/05/tips-tricks-building-boost-wit... also testifies that there are still some wrinkles to be polished out... -- "What Huxley teaches is that in the age of advanced technology, spiritual devastation is more likely to come from an enemy with a smiling face than from one whose countenance exudes suspicion and hate." Neil Postman

On Wed, Dec 26, 2012 at 7:59 AM, rohit dhamija <rohit.dhamija@gmail.com> wrote:
Hi,
Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS
1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason?
Yes. These platforms are not officially supported because no one has volunteered to run regression tests regularly for them. It is not possible for a Boost developer to test on all platforms. So developers depend on the test results of regression tests run by volunteers. For example, see http://beta.boost.org/development/tests/trunk/developer/summary.html If no one volunteers to run the tests for a particular platform, that platform is not officially supported. So if you care about Android or iOS becoming officially supported, start running regular (preferably daily) regression tests for Boost. See http://beta.boost.org/development/running_regression_tests.html --Beman

On Thu, Dec 27, 2012 at 7:12 AM, Beman Dawes <bdawes@acm.org> wrote:
On Wed, Dec 26, 2012 at 7:59 AM, rohit dhamija <rohit.dhamija@gmail.com> wrote:
Hi,
Boost libraries are intended to be widely useful, and usable across a broad range of applications, but yet there is no official support available for Android and iOS
1. Is there any specific reason behind the same (like not optimized for embedded devices)? Or any other reason?
Yes. These platforms are not officially supported because no one has volunteered to run regression tests regularly for them.
It is not possible for a Boost developer to test on all platforms. So developers depend on the test results of regression tests run by volunteers. For example, see http://beta.boost.org/development/tests/trunk/developer/summary.html
If no one volunteers to run the tests for a particular platform, that platform is not officially supported.
So if you care about Android or iOS becoming officially supported, start running regular (preferably daily) regression tests for Boost. See http://beta.boost.org/development/running_regression_tests.html
--Beman
I'm working on porting boost to blackberry10. So at least one mobile platform might have vendor-supported boost. If someone could explain how to get tests built on "host" compiler/system to automatically run on the "target" system, I would set up these regression tests and try to get a dedicated machine to add to the list of test regular regression tests. Tony

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

2013/1/24 Eoin O'Callaghan <eoinocal@gmail.com>:
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:
Why don't we apply this patch to boost trunk? Can someone contact with patch author and ask about the patch license? -- Best regards, Antony Polukhin
participants (10)
-
Antony Polukhin
-
Beman Dawes
-
Domagoj Saric
-
Eoin O'Callaghan
-
Gottlob Frege
-
Klaim - Joël Lamotte
-
Mathias Gaunard
-
rohit dhamija
-
Sergey Cheban
-
Thomas Heller