I am wondering which architectures I should put in the Application.mk file of my Android game.
I want to support all possible platforms that can download games on Google Play and other kinds of Android stores.
I would say that I should set:
APP_ABI := armeabi x86 (as many x86 devices are coming soon as far as I know)
But I wonder if I should not set:
APP_ABI := armeabi armeabi-v7a x86
or
APP_ABI := all
Please clarify.
The Android.mk file resides in a subdirectory of your project's jni/ directory, and describes your sources and shared libraries to the build system. It is really a tiny GNU makefile fragment that the build system parses once or more.
arm64-v8a. This ABI is for ARMv8-A based CPUs, which support the 64-bit AArch64 architecture. It includes the Advanced SIMD (Neon) architecture extensions. You can use Neon intrinsics in C and C++ code to take advantage of the Advanced SIMD extension.
The Native Development Kit (NDK) is a set of tools that allows you to use C and C++ code with Android, and provides platform libraries you can use to manage native activities and access physical device components, such as sensors and touch input.
You can also specify mips
, which would be included when you use all
.
armeabi
code can run on armeabi-v7a
devices, but not the other way around. So you don't need armeabi-v7a
if you have armeabi
, but it will allow you take advantage of hardware floating point operations on some devices.
Also note that the more architectures you include, the larger your resulting APK will be. And if you are regularly compiling for all platforms, your builds will take longer.
Take a look at docs/CPU-ARCH-ABIS.html in your NDK installation for more information about the different architectures.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With