Subject: Re: [boost] RFC/patch: compile boost on Android for platform development
From: Wagner, David (david.wagner_at_[hidden])
Date: 2014-11-17 09:20:20
On 13/11/2014 07:33, Antony Polukhin wrote:
> 2014-11-12 17:30 GMT+04:00 Wagner, David <david.wagner_at_[hidden]>:
>> We are evaluating the pros and cons of using Boost for platform
>> development on Android. We have successfully built and run Asio's "chat"
>> server and client examples on an Android device running Lollipop.
> I've been using Boost on Andriod for a long time and can tell you that the
> major part of Boost libraries work perfectly on Android platforms, even on
> the ancient ones (like 2.3).
> I've been doing some work to run all the regression tests on Andriod, see
> https://github.com/apolukhin/regression_android But unfortunately I had not
> enough time to finish the work. That repo could be a good point to start
> with. Running regression tests is essential for a formal support of Android
> You may also take a look at this thread, it describes the situation with
> android http://lists.boost.org/Archives/boost/2014/01/210885.php
According to the readme on your github repository and the mail you pointed me
to, this is intended for Native development using the NDK (libraries to be used
by Android applications). What I'm talking about is Platform development (below
the Android framework level); if you'd look at the Android architecture diagram
, this would be the green part whereas NDK is the topmost part.
The environment for Platform development is sometimes referred to as "PDK" and
the makefiles in this environment have their own flavor (they look like the ones
in the NDK but the build system is different). While you could theoretically
call bjam in these makefiles, the common practice is to rewrite the makefiles in
the Android flavor. For instance, if boost is ever to be officially integrated
in the PDK, I highly doubt that using bjam would be an option for Google.
A common pattern used by Google in projects part of the PDK is to drop a stable
version of the code into a new git repository and develop android-specific
patches such as the Android makefile on top of it. See the ping6 utility git
history in android  as an example. Also, they are using there own "git
repository aggregation" tool, called "repo". This tool uses an XML file mapping
remote git repositories to locations in the filesystem. Adding boost in its
current modular form would mean adding 110+ projects to the manifest which may
be a bit hard to swallow. These are the reasons why I wrote the makefiles
attached in the original post.
One last thing: you don't have access to the GNU stl in the PDK. Before Lollipop
you only had "STLPort"  which isn't maintained upstream anymore and C++03;
with Lollipop you now have clang's stl and C++11 :)
-- David Wagner PEG->IPG->EIG->Audio CoE complex != complicated --------------------------------------------------------------------- Intel Corporation SAS (French simplified joint stock company) Registered headquarters: "Les Montalets"- 2, rue de Paris, 92196 Meudon Cedex, France Registration Number: 302 456 199 R.C.S. NANTERRE Capital: 4,572,000 Euros This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.