forked from WinMerge/winmerge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
BuildBin.vs2017.cmd
39 lines (32 loc) · 1005 Bytes
/
BuildBin.vs2017.cmd
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
cd /d "%~dp0"
call SetVersion.cmd
cscript /nologo ExpandEnvironmenStrings.vbs Version.in > Version.h
setlocal
for /f "usebackq tokens=*" %%i in (`"%programfiles(x86)%\microsoft visual studio\installer\vswhere.exe" -version [15.0^,16.0^) -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do (
set InstallDir=%%i
)
if exist "%InstallDir%\Common7\Tools\vsdevcmd.bat" (
call "%InstallDir%\Common7\Tools\vsdevcmd.bat
)
if "%1" == "" (
call :BuildBin
call :BuildBin x64
) else (
call :BuildBin %1
)
goto :eof
:BuildBin
set PLATFORM=%1
if "%1" == "" (
set PLATFORM_VS=Win32
) else (
set PLATFORM_VS=%1
)
MSBuild WinMerge.vs2017.sln /t:Rebuild /p:Configuration="Release" /p:Platform="%PLATFORM_VS%" || pause
endlocal
if exist "%SIGNBAT_PATH%" (
call "%SIGNBAT_PATH%" Build\%PLATFORM%\Release\WinMergeU.exe
)
mkdir Build\%PLATFORM%\Release\%APPVER% 2> NUL
copy Build\%PlATFORM%\Release\*.pdb "Build\%PLATFORM%\Release\%APPVER%\"
goto :eof