Can't Create a new Android project

Hello guys,
First of all I want to thank you for creating this awesome project, I love C++ and I have been looking for a nice 2d game engine to work some projects with. The main issue I am having, is that I am trying to create a new Android project, I have everything properly set (SDK, CYGWIN, NDK ver 7 6 and 5 tested),and seems to be running fine with the create-android-project.bat file, but right after the proguard.cfg file is added to the project, the console shows an ERROR Don’t run in cygwin. You should run corresponding bat. And afterwards I can’t continue the process because the build_natives.sh is not in the folder.

I really I want to use this project under windows 7!
Thanks in advance for any responses! :smiley:

Regards from Costa Rica

I know exactly in which line of the batch file it’s crashing :

endlocal & _CYGBIN—login “_CYGSCRIPT” _CURRENTDIR _PROJECTNAME _NDKROOT _PACKAGEPATH “windows”

any ideas ???

Did you modify create-android-project.bat to fit your environment?
What’s the error?
And what’s your cocos2d-x version?

hello and thank you for your reply,
yes I modified it to point correctly at the SDK,CYGWIN and the NDK

the error is

ERROR Don’t run in cygwin. You should run corresponding bat.

and I know its properly going through the .bat file because I wrote some echoes to pin the exact point where the error is happening :

endlocal & *CYGBIN\bash —login “_CYGSCRIPT”*CURRENTDIR PROJECTNAMENDKROOT _PACKAGEPATH “windows”

this is my cocos2dx version : cocos2d-1.0.1-x-0.11.0

**Added the bat file

How did you run create-android-project.bat?

It is the one that comes packaged with cocos2dx

Did you double click create-android-project.bat to run it?

Hi. You can not run .bat scripts in cygwin, cource it’s linux bash emulator, for.sh shell scripts. Just run it from your Windows system prompt Run -> cmd, and it’ll be fine :wink:

Yes, I am double clicking it to run it, and no, I am not running it a batch file from Cygwin, that would make no sense would it???…
my main concern right now is this instruction does:

endlocal & *CYGBIN\bash —login “_CYGSCRIPT”*CURRENTDIR PROJECTNAMENDKROOT _PACKAGEPATH “windows”

because that is where it’ss giving out the error, this is bad because this specifically where it is calling the .sh file, so I am not sure if it may be related to the fact that my paths maybe too long

**Added error screenshot

Nevermind I fixed it, it seems like cygwin doesn’t like spaces in its addresses, so it crashes without notice because it seems to believe that there are less arguments than there actually are,
thank you very much for you replies, perhaps I could write an improved .sh and .bat file that incorporates further information for future users???

Thanks again!