- Mac OS X 10.7+, Xcode 4.6+
- Windows 7+, VS 2012+
- Ubuntu 12.10+, CMake 2.6+
- Python 2.7.5
- NDK, JDK, ANT (Android development)
- iOS 5.0+ for iPhone / iPad games
- Android 2.3+ for Android games
- Windows Phone 8+ for Windows Phone games
- OS X v10.6+ for Mac games
- Windows 7+ for Windows games
Download everything below:
After downloading everything above,
unzip the Android SDK and NDK to the same root location. (maybe:
install Python and take note of where you placed it.
extract Apache Ant and place the entire folder where you wish to keep it. Take note of where you placed it.
now, test your environment before continuing. Launch a command prompt and execute:
If everything works it is time to run setup.py to configure your Android development environment. This will set the necessary environment variables needed. If you haven’t configured this environment before, you will be prompted to enter paths for variables that are not found. You run setup.py from the directory Cocos2d-x is in.
Inside your Cocos2d-x directory run:
caution: You must not use the ~ sign. Use the full path to your home directory. Otherwise, the scripts will fail due to error path value.
- Now it will ask for NDK_ROOT path. Here, enter the extracted NDK directory
- SDK_ROOT. Here, enter the Android SDK path:
- ANT_ROOT. Here, enter the Apache ANT bin path:
Vola, the cocos2d-x has been successfully setup on your system.
if you want to reproduce, please indicate the source:
Getting started with cocos2d-x – Installation or Setup(Windows) - CodeDay