0

当我开始用 ndk 编译 helloCpp 时,我无法摆脱这个错误。我获得了所有用户的适当许可。请任何人都可以提供线索吗?我也将 NDK_ROOT 包含在系统变量中。

dell@dell-PC /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android
$ ./build_native.sh
NDK_ROOT = /cygdrive/C/android-ndk-r8e
COCOS2DX_ROOT = /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android/../../../..
APP_ROOT = /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android/..
APP_ANDROID_ROOT = /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android            Using prebuilt externals
 ++ /cygdrive/C/android-ndk-r8e/ndk-build -C /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android NDK_MODULE_PATH=/cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android/../../../..:/cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android/../../../../cocos2dx/platform/third_party/android/prebuilt
make.exe: *** /cygdrive/C/cocos2d-x/samples/Cpp/HelloCpp/proj.android: No such file or directory.  Stop.
4

1 回答 1

0

在此处遵循本教程。将这些包含在路径和符号中 <- C/C++ 常规 <- 属性 <- 右键单击​​项目浏览并设置安装 NDK 的位置。

/库/Android/android-ndk-r8/sources/cxx-stl/gnu-libstdc++/include

/Library/Android/android-ndk-r8/platforms/android-8/arch-arm/usr/include

/库/Android/android-ndk-r8/sources/cxx-stl/system/include

/库/Android/android-ndk-r8/sources/cxx-stl/gabi++/include

在 Build->Toolchain 下选择 Android Gcc -> make 然后在 C/C++ build -> build 命令下重置变量

将其重置为

bash ${workspace_loc:/YOURPROJECTNAME}/build_native.sh NDK_DEBUG=1 V=1

不要忘记在构建命令中更改项目名称。

于 2013-07-29T09:16:00.970 回答