Android NDK could not be resolved

来源:互联网 发布:以人为镜知得失的意思 编辑:程序博客网 时间:2024/04/30 02:58

Android NDK *** could not be resolved

经实验是准确的,ubuntu12.1,android-21,android-ndk-r10c-linux-x86_64.bin(2014.11.16

Type '*****' could not be resolved

Method '******' could not be resolved

等等很多诸如此类的错误


解决方法:

打开eclipse,在native工程上右键Properties>preferences

C/C++ General -> Path and Symbols

选择include标签,单击Add,在弹出的窗口中,选择Filesystem...,选择/home/???/adt/sdk/ndk/platforms/android-21/arch-arm64/usr/include目录,

(???处填写你的用户名)且选中All  languages.

最后Apply-> OK



============

http://blog.sina.com.cn/s/blog_7b83134b0101boel.html

(2013-05-23 19:50:51)

Type '*****' could not be resolved

Method '******' could not be resolved

等等很多诸如此类的错误


解决方法:

是由于没有将jni.h导入的缘故,而这个文件在ndk的目录下面。所以,参照以下步骤:

Project Properties -> C/C++ General-> Path and Symbols

选择include标签,Add-> $Android_NDK_HOME/platforms/android-14/arch-arm/usr/include

且选中Alllanguages.

最后Apply-> OK

这样错误就解决了。





/*****************************************************************************************/

2014.12.3以上的方法失效了,用以下的方法.

在help->install new software中,Add :   http://download.eclipse.org/tools/cdt/releases/indigo

之后选中第一个,next即可.



0 0