cocos2d/cocos2d-x — pull request #2046 by rohankuruvilla (2013-02-26 08:06:33+00:00)
Title: Eclipse Project import (DO NOT MERGE. Need to add Documentation and also needs to be tested)

Allows cocos2d-x Android projects to easily be included in Eclipse.

Features:

1. Complete workflow from Eclipse. Including
a. Build C++
b. Clean C++
c. Build and Run whole project
d. Logcat view
2. True C++ editing, including
a. Code completion
b. Jump to definition
c. Refactoring tools etc.
d. Quick open C++ files

Pre-Instructions for warming up Eclipse.

1. set NDK_ROOT in environment. for eg. export NDK_ROOT=/path/to/ndk/

2. Import libcocos2dx project as new Android Application project. Steps:
a. File->new->Project..->Android Project From Existing Code
b. Click Browse button and open cocos2dx/platform/android/java directory

3. Set one Workspace Path Variable for cocos2d-x root. Steps:
a. Eclipse->Preferences->General->Workspace->Linked Resources
b. Click the New button to add a variable called "COCOS2DX" and point it to the root cocos2d-x directory (Directory containing cocos2dx, external, scripting, tools etc.)

NOTE: These steps need to be done only once. After this you can import as many projects as need be, with no additional modifications

Now you can create new project using project creator, or open a sample project.

Note: Open proj.android folder from File->New->Project..->Android Project From Existing Code

TODO:

1. Testing.
2. Documentation
3. NDK-GDK support within Eclipse
4. Improve initial workflow if possible