OSDN Git Service

Update Contributors.txt
[winmerge-jp/winmerge-jp.git] / BuildBin.vs2019.cmd
index 9c27455..95e9977 100644 (file)
@@ -4,7 +4,7 @@ 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" -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do (
+for /f "usebackq tokens=*" %%i in (`"%programfiles(x86)%\microsoft visual studio\installer\vswhere.exe" -version [16.0^,17.0^) -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do (
   set InstallDir=%%i
 )
 if exist "%InstallDir%\Common7\Tools\vsdevcmd.bat" (
@@ -12,29 +12,24 @@ if exist "%InstallDir%\Common7\Tools\vsdevcmd.bat" (
 )
 
 if "%1" == "" (
-  call :BuildBin
-  call :BuildBin x64
+  call :BuildBin ARM || goto :eof
+  call :BuildBin ARM64 || goto :eof
+  call :BuildBin x86|| goto :eof
+  call :BuildBin x64 || goto :eof
 ) else (
-  call :BuildBin %1 
+  call :BuildBin %1 || goto :eof
 )
 
 goto :eof
 
 :BuildBin
-set PLATFORM=%1
-if "%1" == "" (
-  set PLATFORM_VS=Win32
-) else (
-  set PLATFORM_VS=%1
-)
-MSBuild WinMerge.vs2019.sln /t:Rebuild /p:Configuration="Release Unicode" /p:Platform="%PLATFORM_VS%" || pause
+MSBuild WinMerge.vs2019.sln /t:Rebuild /p:Configuration="Release" /p:Platform="%1" || goto :eof
 endlocal
 
 if exist "%SIGNBAT_PATH%" (
-  call "%SIGNBAT_PATH%" Build\%PLATFORM%\MergeUnicodeRelease\WinMergeU.exe
-  call "%SIGNBAT_PATH%" Build\%PLATFORM%\MergeUnicodeRelease\MergeLang.dll
+  call "%SIGNBAT_PATH%" Build\%1\Release\WinMergeU.exe
 )
 
-mkdir Build\%PLATFORM%\MergeUnicodeRelease\%APPVER% 2> NUL
-copy Build\%PlATFORM%\MergeUnicodeRelease\*.pdb "Build\%PLATFORM%\MergeUnicodeRelease\%APPVER%\"
+mkdir Build\%1\Release\%APPVER% 2> NUL
+copy Build\%1\Release\*.pdb "Build\%1\Release\%APPVER%\"
 goto :eof