setup CoCos2d-x project


一)建立一个新的coscos2d-x project

1)在ubuntu下面,建立编译环境的文章:

http://blog.csdn.net/jamesjiangchn/article/details/8734586

step 2)

copy the java lib into the new project
 
http://www.mobibrw.com/?p=332
 

二   从coscos2d-x 已经有的Project 创建项目

 
example:
 1)
cd cocos2d-x-2.1.4/samples/Cpp/TestCpp/proj.android
 2)
 edit build_native.sh,  write you NDK path here
 
    NDK_ROOT=~/bin/android-nkd-r8e        
 
3)
  ./build_native.sh
 
this will build the code in ../Classes according to ../Android.mk file
and install the so lib into the libs/
 
4)
copy the java lib
 
~/github/talkingcat/cocos2d-x-2.1.4/cocos2dx/platform/android/java/src/org/cocos2dx$
cp -r lib/  ../../../../../../../samples/Cpp/TestCpp/proj.android/src/org/cocos2dx/
 
5)
 launch the eclipse, create the project from exsiting code base
 
 
posted on 2013-07-21 22:37  keniee  阅读(241)  评论(0编辑  收藏  举报