-
Notifications
You must be signed in to change notification settings - Fork 0
/
BuildRelease.bat
78 lines (57 loc) · 1.75 KB
/
BuildRelease.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
ECHO OFF
CLS
pushd %~dp0
set REPO=%CD%
ECHO REPO=%REPO%
if NOT EXIST %REPO%\Core exit
if NOT EXIST %REPO%\Plugins exit
ECHO ON
REM - Remember to update ToDoList version number
REM - Remember to pull latest translations
pause
REM - Build core app in VC6
cd %REPO%\Core
REM - Detours
REM "C:\Program Files (x86)\Microsoft Visual Studio\Common\MSDev98\Bin\msdev.exe" .\3rdParty\Detours\Detours.dsw /MAKE "ALL - Win32 Unicode Release"
REM - Core app
set OUTPUT_FILE=%REPO%\Core\ToDoList\Unicode_Release\Core_Build_Output.txt
"C:\Program Files (x86)\Microsoft Visual Studio\Common\MSDev98\Bin\msdev.exe" .\ToDoList_Core.dsw /MAKE "ALL - Win32 Unicode Release" /OUT %OUTPUT_FILE%
REM - Check for compile errors
ECHO OFF
findstr /C:") : error" %OUTPUT_FILE%
if %errorlevel%==1 (
REM - Check for link errors
findstr /C:"Error executing link.exe" %OUTPUT_FILE%
)
if %errorlevel%==0 (
echo Build Errors!
pause
exit
)
REM Run units tests
ECHO ON
cd TDLTest\Unicode_Release
TDLTest > %OUTPUT_FILE%
ECHO OFF
findstr /C:"tests FAILED" %OUTPUT_FILE%
if %errorlevel%==0 (
echo Test Errors!
pause
exit
)
REM - Build plugins using MSBuild for reliability
ECHO ON
SET MSBUILD="C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe"
SET BUILDPARAMS=/t:Build /p:Configuration=Release /m /v:normal /noWarn:MSB3267;MSB3305;LNK4248;CS1762;LNK4221;MSB3026
REM - This is required to get the warning suppression to work
SET VCTargetsPath=C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\
cd %REPO%\Plugins
%MSBUILD% .\ToDoList_Plugins.sln %BUILDPARAMS%
REM - Allow caller to cancel building Zip
pause
CALL %REPO%\BuildReleaseZip.bat
CALL %REPO%\BuildCodeZip.bat
REM - Open Downloads folder
Explorer.exe "%REPO%\..\ToDoList_Downloads\Latest"
popd
pause