--- 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