1、Android develop上下载ndkfor android
https://developer.android.com/ndk/downloads/index.html#extract
2、解压那个bin文件,无法直接打开,我使用命令来解压,打开终端,进入bin所在文件夹,输入
chmod a+x chmod a+x android-ndk-r10e-darwin-x86_64.bin
./android-ndk-r10e-darwin-x86_64.bin
3、新建一个AS工程,参考http://blog.csdn.net/qiujuer/article/details/42040963,成功,注意文件的命名以及native函数的命名