ndk-build编译出错:Android NDK: APP_PLATFORM not set. Defaulting to minimum supported version android-14
cmd命令行报错信息,如下:
PS D:\whx\AndroidStudioProject\VolumeII\Sample8_4\src\main\jni> ndk-build
Android NDK: APP_PLATFORM not set. Defaulting to minimum supported version android-14.
Android NDK: WARNING: APP_PLATFORM android-14 is higher than android:minSdkVersion 1 in D:/whx/AndroidStudioProject/VolumeII/Sample8_4/src/main/AndroidManifest.xml. NDK binaries will *not* be comptible with devices older than android-14. See https://android.googlesource.com/platform/ndk/+/master/docs/user/common_problems.md for more information.
Android NDK: NDK Application 'local' targets unknown ABI(s): all //鎸囨槑缂栬瘧鍜岃皟璇曠殑CPU鏋舵瀯
Android NDK: Please fix the APP_ABI definition in D:/whx/AndroidStudioProject/VolumeII/Sample8_4/src/main/jni/Application.mk
D:/development/tools/android-ndk-r16b/build//../build/core/setup-app.mk:75: *** Android NDK: Aborting . Stop.
PS D:\whx\AndroidStudioProject\VolumeII\Sample8_4\src\main\jni> ndk-build
Android NDK: APP_PLATFORM not set. Defaulting to minimum supported version android-14.
Android NDK: WARNING: APP_PLATFORM android-14 is higher than android:minSdkVersion 1 in D:/whx/AndroidStudioProject/VolumeII/Sample8_4/src/main/AndroidManifest.xml. NDK binaries will *not* be comptible with devices older than android-14. See https://android.googlesource.com/platform/ndk/+/master/docs/user/common_problems.md for more information.
解决办法:
1、首先,修改项目默认最小android版本,由最小14改为大于14的其他版本。
2、然后,修改Application.mk文件,删除APP_ABI := all 语句,即可。
更多相关文章
- Android 编程获取手机型号,本机电话号码,sdk版本及firmware版本号(
- Android进阶之android应用的SDK版本之间的切换
- ffmpeg3.3 编译 android 系统版本 32位 和64 位 动态库
- 实时获取Android 各版本电量的统一方法
- PC&移动平台设备检测库(平台、版本、操作系统、方向)
- android历史版本
- Android后台保活,这里有你需要的所有姿势。2019,基于API26 Android
- 利用productFlavors实现一套代码打包多版本