1.NDK_ROOT :"please define NDK_ROOT"

解决:

在build_native.sh 中添加路径

NDK_ROOT="/Users/pc/Documents/android/android-ndk-r9d"

 

2.加密库cryptopp编译不过,错误fd_set 不认识

解决:http://morgwai.pl/ndkTutorial/

The last problem is that Crypto++ seems to rely on implicit inclusion of header file containing definition of fd_set. This is not the case when using STLport so you need to add the following preprocessor command somewhere in wait.h file:

#include <sys/select.h>

3.CCCommon.cpp 文件报错:

/cocos2dx/platform/android/CCCommon.cpp:54:77: error: format not a string literal and no format arguments [-Werror=format-security]

some warnings being treated as errors

解决:

修改自己项目 proj.android\jni\Application.mk (不是Android.mk)文件,在最后加上

APP_CPPFLAGS += -Wno-error=format-security 就可以了。

 

4.libluajit.a(lib_base.o):lib_base.c:function lj_cf_print: error: undefined reference to '__swbuf'

解决:http://cocos2d-x.org/news/307

We suggest you not to use NDK r10. Please use NDK r9d instead.

NDK r9d url

相关文章:

  • 2021-06-16
  • 2021-08-22
  • 2022-12-23
  • 2021-05-13
  • 2021-10-31
  • 2021-07-31
  • 2021-06-07
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-25
  • 2021-08-02
  • 2021-06-29
  • 2021-12-04
  • 2022-12-23
相关资源
相似解决方案