Summary

This chapter introduced a fundamental aspect of the NDK: portability. Thanks to the recent improvements in the building toolchain, the Android NDK can now take advantage of the vast C/C++ ecosystem. It unlocks the door of a productive environment, where code is shared with other platforms with the aim of creating new cutting-edge applications efficiently.

More specifically, you learned how to activate the STL with a simple flag in the NDK makefile system. We have ported the Box2D library into an NDK module that is reusable among Android projects. You also saw how to prebuild Boost using the raw NDK toolchain, without any wrapper. We have enabled exceptions and RTTI and discovered in depth how to write module makefiles.

We have highlighted ...

Get Android NDK Beginner's Guide - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.