-
-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathbuild.bat
More file actions
23 lines (16 loc) · 698 Bytes
/
build.bat
File metadata and controls
23 lines (16 loc) · 698 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
@echo off
setlocal
cd /d %~dp0
rem add MSVC in PATH
call :SubVSPath
if not exist "%VS_PATH%" echo ERROR: Visual Studio NOT FOUND! & goto end
call "%VS_PATH%\Common7\Tools\VsDevCmd.bat" -arch=amd64
set "MSBUILD_SWITCHES=/nologo /consoleloggerparameters:Verbosity=minimal /maxcpucount /nodeReuse:true"
MSBuild.exe "jpegoptim.sln" %MSBUILD_SWITCHES% /target:"Rebuild" /property:Configuration="Release";Platform="x64"
:end
endlocal
if not defined CI pause
exit /b
:SubVSPath
for /f "delims=" %%A in ('"%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe" -property installationPath -latest -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64') do set "VS_PATH=%%A"
exit /b