我运行了NDK项目,然后输入命令。它会生成错误。我不知道如何解决它。
这是命令。
hieund@hieund:~/Programs/AndroidNDK/samples/hello-gl2$ $NDK_HOME/ndk-gdb
/home/hieund/Programs/AndroidNDK/build/core/build-local.mk:40: build/core/init.mk: No such file or directory
/home/hieund/Programs/AndroidNDK/build/core/build-local.mk:166: /add-application.mk: No such file or directory
/home/hieund/Programs/AndroidNDK/build/core/build-local.mk:174: /setup-imports.mk: No such file or directory
/home/hieund/Programs/AndroidNDK/build/core/build-local.mk:191: /build-all.mk: No such file or directory
make: *** No rule to make target `/build-all.mk'. Stop.
ERROR: The device does not support the application's targetted CPU ABIs!
Device supports: armeabi-v7a armeabi
Package supports:
我检查了make的版本,没关系。
hieund@hieund:~/Programs/AndroidNDK/samples/hello-gl2$ make -version
GNU Make version 3.75, by Richard Stallman and Roland McGrath.
Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 95, 96
Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Report bugs to <bug-gnu-utils@prep.ai.mit.edu>.
答案 0 :(得分:1)
The device does not support the application's targetted CPU ABIs!
您正在构建一个您的设备不支持的库。检查您的设备CPU ABI
String abi=Build.CPU_ABI;
Toast.makeText(CpuinfoActivity.this, "CPU ABI is :::"+abi, Toast.LENGTH_LONG).show();
答案 1 :(得分:1)
我认为问题是ndk-gdb找不到最新的make。此命令修复了问题:
export GNUMAKE=/usr/bin/make
答案 2 :(得分:0)
ndk-gdb
期待Linux上的某些环境。我运行如下:
>ANDROID_NDK_ROOT=/etc/android-ndk-r8b GNUMAKE=/etc/android-ndk-r8b/prebuilt/linux-x86/bin/make ndk-gdb
如果您愿意,可以使用/usr/bin/make
。