Cocos2dx - 为Android编译

时间:2014-02-13 10:54:27

标签: android cocos2d-x

****构建配置默认为项目HelloCpp ****

bash C:/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/build_native.sh 
cygwin warning:
MS-DOS style path detected: C:\Development\cocos2d-x-2.2.2\samples\Cpp\HelloCpp\proj.android
Preferred POSIX equivalent is: /cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android
CYGWIN environment variable option "nodosfilewarning" turns off this warning.
Consult the user's guide for more details about POSIX paths:
http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
NDK_ROOT = C:\Development\ndk;C:\cygwin64\bin;C:\Development\ndk;C:\cygwin64\bin
COCOS2DX_ROOT = /cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/../../../..
APP_ROOT = /cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/..
APP_ANDROID_ROOT = /cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android
Using prebuilt externals
+ 'C:\Development\ndk;C:\cygwin64\bin;C:\Development\ndk;C:\cygwin64\bin/ndk-build' -C /cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android NDK_MODULE_PATH=/cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/../../../..:/cygdrive/c/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/../../../../cocos2dx/platform/third_party/android/prebuilt
C:/Development/cocos2d-x-2.2.2/samples/Cpp/HelloCpp/proj.android/build_native.sh: line 90: **C:\Development\ndk;C:\cygwin64\bin;C:\Development\ndk;C:\cygwin64\bin/ndk-build: No such file or directory

**构建完成**

image

我不确定为什么这会给我这个错误。任何帮助将不胜感激。 提前谢谢。

1 个答案:

答案 0 :(得分:0)

我找到了这个问题的答案,我在eclipse项目中编辑了NDK_ROOT。像这样。

http://i.imgur.com/RJyE1ZB.png

这就是为什么它在NDK_ROOT中给出了那个奇怪的路径,现在我不再有这个问题了。但该应用程序并没有在我的手机上运行。每当我尝试安装它时,它会显示“App not installed”。