updated win build script
authorbovi
Sun, 15 Jan 2012 22:29:24 +0100
changeset 6569 64f9fbd48b9e
parent 6568 ad83229a7d98
child 6570 216a5ccadf0e
updated win build script
tools/build_windows.bat
--- a/tools/build_windows.bat	Sun Jan 15 21:08:15 2012 +0100
+++ b/tools/build_windows.bat	Sun Jan 15 22:29:24 2012 +0100
@@ -17,19 +17,29 @@
 xcopy /d/y %QTDIR%\libgcc_s_dw2-1.dll .
 xcopy /d/y %QTDIR%\mingwm10.dll .
 
+echo Setting up the environment...
 call %QTDIR%\qtenv2.bat
+
 echo Running cmake...
+set errorlevel=
 cmake -G "MinGW Makefiles" -DCMAKE_INCLUDE_PATH="%CD%\..\misc\winutils\include" -DCMAKE_LIBRARY_PATH="%CD%\..\misc\winutils\lib" ..
 
+if %errorlevel% NEQ 0 goto exit
+
 echo Running make...
+set errorlevel=
 mingw32-make -lSDL -lSDL_Mixer install
 
+if %errorlevel% NEQ 0 goto exit
+
 echo Creating shortcut...
 if /i "%PROGRAMFILES(X86)%"=="" (
 	COPY /y ..\misc\winutils\Hedgewars_x86.lnk C:\%HOMEPATH%\Desktop\Hedgewars.lnk 
 ) else (
 	COPY /y ..\misc\winutils\Hedgewars_x64.lnk C:\%HOMEPATH%\Desktop\Hedgewars.lnk
 )
+echo ALL DONE, Hedgewars has been successfully compiled and installed
 
-echo ALL DONE, Hedgewars has been successfully compiled and installed
+:exit
+cd ../tools
 pause