mirror of https://github.com/axmolengine/axmol.git
Merge pull request #1781 from minggo/iss1603-adjust-directory
issue #1603:modify some auto-building script
This commit is contained in:
commit
7ca4934850
|
@ -91,12 +91,12 @@ IsTestCpp=1
|
||||||
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cd samples/Cpp/TestCpp/proj.android
|
cd $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
sh rootconfig-mac.sh TestCpp
|
sh rootconfig-mac.sh TestCpp
|
||||||
sh build_native.sh
|
sh build_native.sh
|
||||||
|
|
||||||
#update android project configuration files
|
#update android project configuration files
|
||||||
cd ..
|
cd $ROOT/samples/Cpp/TestCpp
|
||||||
android update project -p proj.android
|
android update project -p proj.android
|
||||||
cd proj.android
|
cd proj.android
|
||||||
antcompile
|
antcompile
|
||||||
|
@ -106,10 +106,10 @@ IsTestCpp=0
|
||||||
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/HelloCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/HelloCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/HelloCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/HelloCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/HelloCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/HelloCpp/proj.android
|
||||||
cd ../../Cpp/HelloCpp/proj.android
|
cd $ROOT/samples/Cpp/HelloCpp/proj.android
|
||||||
sh rootconfig-mac.sh HelloCpp
|
sh rootconfig-mac.sh HelloCpp
|
||||||
sh build_native.sh
|
sh build_native.sh
|
||||||
cd ..
|
cd $ROOT/samples/Cpp/HelloCpp
|
||||||
android update project -p proj.android
|
android update project -p proj.android
|
||||||
cd proj.android
|
cd proj.android
|
||||||
antcompile
|
antcompile
|
||||||
|
@ -117,16 +117,16 @@ antcompile
|
||||||
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Lua/HelloLua/proj.android
|
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Lua/HelloLua/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Lua/HelloLua/proj.android
|
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Lua/HelloLua/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Lua/CppHelloLua/proj.android
|
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Lua/CppHelloLua/proj.android
|
||||||
cd ../../Lua/HelloLua/proj.android
|
cd $ROOT/samples/Lua/HelloLua/proj.android
|
||||||
sh rootconfig-mac.sh HelloLua
|
sh rootconfig-mac.sh HelloLua
|
||||||
sh build_native.sh
|
sh build_native.sh
|
||||||
cd ..
|
cd $ROOT/samples/Lua/HelloLua
|
||||||
android update project -p proj.android
|
android update project -p proj.android
|
||||||
cd proj.android
|
cd proj.android
|
||||||
antcompile
|
antcompile
|
||||||
|
|
||||||
#return the compileresult.
|
#return the compileresult.
|
||||||
cd ../../..
|
cd $ROOT
|
||||||
if [ $compileresult != 0 ]; then
|
if [ $compileresult != 0 ]; then
|
||||||
# git checkout -f
|
# git checkout -f
|
||||||
# git clean -df -x
|
# git clean -df -x
|
||||||
|
|
|
@ -49,7 +49,7 @@ IsTestCpp=1
|
||||||
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/ant.properties $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/build.xml $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/TestCpp/proj.android
|
cp $ROOT/tools/jenkins_scripts/mac/rootconfig-mac.sh $ROOT/samples/Cpp/TestCpp/proj.android
|
||||||
cd samples/TestCpp/proj.android
|
cd samples/Cpp/TestCpp/proj.android
|
||||||
sh rootconfig-mac.sh TestCpp
|
sh rootconfig-mac.sh TestCpp
|
||||||
sh build_native.sh
|
sh build_native.sh
|
||||||
|
|
||||||
|
|
|
@ -13,16 +13,17 @@ if not exist "%ANT_HOME%" echo Couldn't find Ant at "%ANT_HOME%" and you should
|
||||||
|
|
||||||
set _PROJECTNAME=TestCpp
|
set _PROJECTNAME=TestCpp
|
||||||
set _LANGUAGE_=Cpp
|
set _LANGUAGE_=Cpp
|
||||||
cd ..\..\..\..
|
set _ROOT_=%cd%\..\..\..\..
|
||||||
|
cd %_ROOT_%
|
||||||
|
|
||||||
:project
|
:project
|
||||||
::Copy build Configuration files to target directory
|
::Copy build Configuration files to target directory
|
||||||
copy %cd%\tools\jenkins_scripts\ant.properties %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
copy %_ROOT_%\tools\jenkins_scripts\ant.properties %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
||||||
copy %cd%\tools\jenkins_scripts\build.xml %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
copy %_ROOT_%\tools\jenkins_scripts\build.xml %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
||||||
copy %cd%\tools\jenkins_scripts\windows\android\rootconfig.sh %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
copy %_ROOT_%\tools\jenkins_scripts\windows\android\rootconfig.sh %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android /Y
|
||||||
|
|
||||||
::Modify the configuration files
|
::Modify the configuration files
|
||||||
cd samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
cd %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
rootconfig.sh %_PROJECTNAME%
|
rootconfig.sh %_PROJECTNAME%
|
||||||
cd ..
|
cd ..
|
||||||
set _PROJECTLOCATION=%cd%
|
set _PROJECTLOCATION=%cd%
|
||||||
|
@ -129,7 +130,7 @@ if "%%a"=="target=android-13" (echo/target=android-8)else echo/%%a
|
||||||
move anttmp.properties ant.properties
|
move anttmp.properties ant.properties
|
||||||
|
|
||||||
::Calculate the errorlevel and change build target.
|
::Calculate the errorlevel and change build target.
|
||||||
cd ..\..\..
|
cd %_ROOT_%
|
||||||
if "%_PROJECTNAME%"=="TestCpp" set /a TestCpp_Result=(result8+result10+result11+result12+result13) && set _PROJECTNAME=HelloCpp&& goto project
|
if "%_PROJECTNAME%"=="TestCpp" set /a TestCpp_Result=(result8+result10+result11+result12+result13) && set _PROJECTNAME=HelloCpp&& goto project
|
||||||
if "%_PROJECTNAME%"=="HelloCpp" set /a HelloCpp_Result=(result8+result10+result11+result12+result13) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
if "%_PROJECTNAME%"=="HelloCpp" set /a HelloCpp_Result=(result8+result10+result11+result12+result13) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
||||||
if "%_PROJECTNAME%"=="HelloLua" set /a HelloLua_Result=(result8+result10+result11+result12+result13)
|
if "%_PROJECTNAME%"=="HelloLua" set /a HelloLua_Result=(result8+result10+result11+result12+result13)
|
||||||
|
|
|
@ -12,16 +12,17 @@ if not exist "%ANT_HOME%" echo Couldn't find Ant at "%ANT_HOME%" and you should
|
||||||
|
|
||||||
set _PROJECTNAME=TestCpp
|
set _PROJECTNAME=TestCpp
|
||||||
set _LANGUAGE_=Cpp
|
set _LANGUAGE_=Cpp
|
||||||
cd ..\..\..\..
|
set _ROOT_=%cd%\..\..\..\..
|
||||||
|
cd %_ROOT_%
|
||||||
|
|
||||||
:project
|
:project
|
||||||
::Copy build Configuration files to target directory
|
::Copy build Configuration files to target directory
|
||||||
copy %cd%\tools\jenkins_scripts\ant.properties %cd%\samples\%_LANGUANE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\ant.properties %_ROOT_%\samples\%_LANGUANE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\build.xml %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\build.xml %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\windows\android\rootconfig.sh %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\windows\android\rootconfig.sh %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
|
|
||||||
::Modify the configuration files
|
::Modify the configuration files
|
||||||
cd samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
cd %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
rootconfig.sh %_PROJECTNAME%
|
rootconfig.sh %_PROJECTNAME%
|
||||||
cd ..
|
cd ..
|
||||||
set _PROJECTLOCATION=%cd%
|
set _PROJECTLOCATION=%cd%
|
||||||
|
@ -146,7 +147,7 @@ for /f "delims=" %%a in (ant.properties) do set num=%%a&call :lis
|
||||||
move ant1.properties ant.properties
|
move ant1.properties ant.properties
|
||||||
|
|
||||||
::Calculate the errorlevel and change build target.
|
::Calculate the errorlevel and change build target.
|
||||||
cd ..\..\..
|
cd %_ROOT_%
|
||||||
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result8+result10+result11+result12+result13) && set _PROJECTNAME=HelloCpp&& goto project
|
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result8+result10+result11+result12+result13) && set _PROJECTNAME=HelloCpp&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result8+result10+result11+result12+result13) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result8+result10+result11+result12+result13) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result8+result10+result11+result12+result13)
|
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result8+result10+result11+result12+result13)
|
||||||
|
|
|
@ -12,16 +12,17 @@ if not exist "%ANT_HOME%" echo Couldn't find Ant at "%ANT_HOME%" and you should
|
||||||
|
|
||||||
set _PROJECTNAME=TestCpp
|
set _PROJECTNAME=TestCpp
|
||||||
set _LANGUAGE_=CPP
|
set _LANGUAGE_=CPP
|
||||||
cd ..\..\..\..
|
set _ROOT_=%cd%\..\..\..\..
|
||||||
|
cd _ROOT_
|
||||||
|
|
||||||
:project
|
:project
|
||||||
::Copy build Configuration files to target directory
|
::Copy build Configuration files to target directory
|
||||||
copy %cd%\tools\jenkins_scripts\ant.properties %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\ant.properties %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\build.xml %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\build.xml %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\windows\android\rootconfig.sh %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\windows\android\rootconfig.sh %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
|
|
||||||
::Modify the configuration files
|
::Modify the configuration files
|
||||||
cd samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
cd %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
rootconfig.sh %_PROJECTNAME%
|
rootconfig.sh %_PROJECTNAME%
|
||||||
cd ..
|
cd ..
|
||||||
set _PROJECTLOCATION=%cd%
|
set _PROJECTLOCATION=%cd%
|
||||||
|
@ -85,7 +86,7 @@ if "%%a"=="target=android-15" (echo/target=android-8)else echo/%%a
|
||||||
move anttmp.properties ant.properties
|
move anttmp.properties ant.properties
|
||||||
|
|
||||||
::Calculate the errorlevel and change build target.
|
::Calculate the errorlevel and change build target.
|
||||||
cd ../../..
|
cd %_ROOT_%
|
||||||
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result14+result15) && set _PROJECTNAME=HelloCpp&& goto project
|
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result14+result15) && set _PROJECTNAME=HelloCpp&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result14+result15) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result14+result15) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result14+result15)
|
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result14+result15)
|
||||||
|
|
|
@ -12,16 +12,17 @@ if not exist "%ANT_HOME%" echo Couldn't find Ant at "%ANT_HOME%" and you should
|
||||||
|
|
||||||
set _PROJECTNAME=TestCpp
|
set _PROJECTNAME=TestCpp
|
||||||
set _LANGUAGE=Cpp
|
set _LANGUAGE=Cpp
|
||||||
cd ..\..\..\..
|
set _ROOT_=%cd%\..\..\..\..
|
||||||
|
cd %_ROOT_%
|
||||||
|
|
||||||
:project
|
:project
|
||||||
::Copy build Configuration files to target directory
|
::Copy build Configuration files to target directory
|
||||||
copy %cd%\tools\jenkins_scripts\ant.properties %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\ant.properties %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\build.xml %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\build.xml %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
copy %cd%\tools\jenkins_scripts\windows\android\rootconfig.sh %cd%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
copy %_ROOT_%\tools\jenkins_scripts\windows\android\rootconfig.sh %_ROOT_%\samples\%_LANGUAGE_%\%_PROJECTNAME%\proj.android
|
||||||
|
|
||||||
::Modify the configuration files
|
::Modify the configuration files
|
||||||
cd samples\%_PROJECTNAME%\proj.android
|
cd %_ROOT_%\samples\%_PROJECTNAME%\proj.android
|
||||||
rootconfig.sh %_PROJECTNAME%
|
rootconfig.sh %_PROJECTNAME%
|
||||||
cd ..
|
cd ..
|
||||||
set _PROJECTLOCATION=%cd%
|
set _PROJECTLOCATION=%cd%
|
||||||
|
@ -94,7 +95,7 @@ for /f "delims=" %%a in (ant.properties) do set num=%%a&call :lis
|
||||||
move ant1.properties ant.properties
|
move ant1.properties ant.properties
|
||||||
|
|
||||||
::Calculate the errorlevel and change build target.
|
::Calculate the errorlevel and change build target.
|
||||||
cd ..\..\..
|
cd %_ROOT_%
|
||||||
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result14+result15) && set _PROJECTNAME=HelloCpp&& goto project
|
IF "%_PROJECTNAME%"=="TestCpp" set /a testresult1=(result14+result15) && set _PROJECTNAME=HelloCpp&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result14+result15) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
IF "%_PROJECTNAME%"=="HelloCpp" set /a testresult2=(result14+result15) && set _LANGUAGE_=Lua && set _PROJECTNAME=HelloLua&& goto project
|
||||||
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result14+result15)
|
IF "%_PROJECTNAME%"=="HelloLua" set /a testresult3=(result14+result15)
|
||||||
|
|
|
@ -5,7 +5,6 @@
|
||||||
#NDK_ROOT=$($CYGWIN/bin/cygpath.exe $ANDROID_NDK)
|
#NDK_ROOT=$($CYGWIN/bin/cygpath.exe $ANDROID_NDK)
|
||||||
#echo $NDK_ROOT
|
#echo $NDK_ROOT
|
||||||
CUR=$(pwd)
|
CUR=$(pwd)
|
||||||
cd ../../..
|
|
||||||
#tmp=$(pwd)
|
#tmp=$(pwd)
|
||||||
#COCOS2DX=$($CYGWIN/bin/cygpath.exe $tmp)
|
#COCOS2DX=$($CYGWIN/bin/cygpath.exe $tmp)
|
||||||
#echo $COCOS2DX
|
#echo $COCOS2DX
|
||||||
|
@ -31,13 +30,13 @@ if [ $1 = TestCpp ]; then
|
||||||
elif [ $1 = HelloCpp ]; then
|
elif [ $1 = HelloCpp ]; then
|
||||||
sed -i '2d' $CUR/build.xml
|
sed -i '2d' $CUR/build.xml
|
||||||
sed -i '2 i\<project name="HelloCpp" default="help">' $CUR/build.xml
|
sed -i '2 i\<project name="HelloCpp" default="help">' $CUR/build.xml
|
||||||
else [ $1 = HelloLua ]; then
|
elif [ $1 = HelloLua ]; then
|
||||||
sed -i '2d' $CUR/build.xml
|
sed -i '2d' $CUR/build.xml
|
||||||
sed -i '2 i\<project name="HelloLua" default="help">' $CUR/build.xml
|
sed -i '2 i\<project name="HelloLua" default="help">' $CUR/build.xml
|
||||||
else [ $1 = TestLua ]; then
|
elif [ $1 = TestLua ]; then
|
||||||
sed -i '2d' $CUR/build.xml
|
sed -i '2d' $CUR/build.xml
|
||||||
sed -i '2 i\<project name="TestLua" default="help">' $CUR/build.xml
|
sed -i '2 i\<project name="TestLua" default="help">' $CUR/build.xml
|
||||||
else [ $1 = TestJavascript ]; then
|
elif [ $1 = TestJavascript ]; then
|
||||||
sed -i '2d' $CUR/build.xml
|
sed -i '2d' $CUR/build.xml
|
||||||
sed -i '2 i\<project name="TestJavascript" default="help">' $CUR/build.xml
|
sed -i '2 i\<project name="TestJavascript" default="help">' $CUR/build.xml
|
||||||
else [ $1 = SimpleGame ]; then
|
else [ $1 = SimpleGame ]; then
|
||||||
|
|
Loading…
Reference in New Issue