Build cpufeatures against the NDK.
If it's built with the platform build system.
So you can use it in unbundled branches:
1. Add the git project ndk to your unbundled branch's repo manifest.
2. LOCAL_STATIC_LIBRARIES += cpufeatures
Change-Id: I702f33bb540de80b4488b9bae3d8b5e1e8c392b6
diff --git a/sources/android/cpufeatures/Android.mk b/sources/android/cpufeatures/Android.mk
index 4ea6f57..7d05ef1 100644
--- a/sources/android/cpufeatures/Android.mk
+++ b/sources/android/cpufeatures/Android.mk
@@ -3,5 +3,14 @@
include $(CLEAR_VARS)
LOCAL_MODULE := cpufeatures
LOCAL_SRC_FILES := cpu-features.c
+
+ifdef HISTORICAL_NDK_VERSIONS_ROOT
+# This is included by the platform build system.
+LOCAL_SDK_VERSION := 9
+LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
+else
+# This is included by the NDK build system.
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)
+endif
+
include $(BUILD_STATIC_LIBRARY)