diff --git a/template/android/.classpath b/template/android/.classpath
new file mode 100644
index 0000000000..a4763d1eec
--- /dev/null
+++ b/template/android/.classpath
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/template/android/.project b/template/android/.project
new file mode 100644
index 0000000000..48a677dea8
--- /dev/null
+++ b/template/android/.project
@@ -0,0 +1,33 @@
+
+
+ HelloCpp
+
+
+
+
+
+ com.android.ide.eclipse.adt.ResourceManagerBuilder
+
+
+
+
+ com.android.ide.eclipse.adt.PreCompilerBuilder
+
+
+
+
+ org.eclipse.jdt.core.javabuilder
+
+
+
+
+ com.android.ide.eclipse.adt.ApkBuilder
+
+
+
+
+
+ com.android.ide.eclipse.adt.AndroidNature
+ org.eclipse.jdt.core.javanature
+
+
diff --git a/template/android/copy_files.sh b/template/android/copy_files.sh
index f208567877..3e3bcfd659 100644
--- a/template/android/copy_files.sh
+++ b/template/android/copy_files.sh
@@ -41,7 +41,7 @@ copy_src_and_jni(){
cp -rf $HELLOWORLD_ROOT/proj.android/jni $APP_DIR/proj.android
cp -rf $HELLOWORLD_ROOT/proj.android/src $APP_DIR/proj.android
- # repalce Android.mk
+ # replace Android.mk
sh $COCOS2DX_ROOT/template/android/gamemk.sh $APP_DIR/proj.android/jni/Android.mk $NEED_BOX2D $NEED_CHIPMUNK $NEED_LUA
}
@@ -56,6 +56,12 @@ copy_build_native(){
chmod u+x $APP_DIR/proj.android/build_native.sh
}
+# copy .project and .classpath and replace project name
+modify_project_classpath(){
+ sed "s/HelloCpp/$APP_NAME/" $COCOS2DX_ROOT/template/android/.project > $APP_DIR/proj.android/.project
+ cp -f $COCOS2DX_ROOT/template/android/.classpath $APP_DIR/proj.android
+}
+
# replace AndroidManifext.xml and change the activity name
# use sed to replace the specified line
modify_androidmanifest(){
@@ -91,6 +97,7 @@ copy_resouces
copy_src_and_jni
copy_library_src
copy_build_native
+modify_project_classpath
modify_androidmanifest
modify_applicationdemo
modify_layout