Building an Android NDK application for different ABIs

Native code is compiled into binaries. Therefore, one set of binaries can only run on a specific architecture. Android NDK comes with techniques and tools to allow developers to compile the same source code for multiple architectures easily.

Getting ready

An Application Binary Interface (ABI) defines how the Android application's machine code is supposed to interact with the system at runtime, including the CPU instruction set, endianness, alignment of memory, and so on. An ABI basically defines a type of architecture.

The following table briefly summarizes the four ABIs supported by Android:

ABI name

Support

Not support

Optional

armeabi

  • ARMv5TE instruction set
  • Thumb (also known as Thumb-1) ...

Get Android Native Development Kit Cookbook 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.