diff --git a/build-gnu.bat b/build-gnu.bat index 5fa0fdae32..d8ed6cb417 100644 --- a/build-gnu.bat +++ b/build-gnu.bat @@ -28,11 +28,25 @@ if "%configuration%" == "Release" ( @rem path=C:\mingw-w64\x86_64-7.2.0-posix-seh-rt_v5-rev1\mingw64\bin;%path% path=C:\msys64\usr\bin;%path:C:\msys64\usr\bin;=% path=C:\msys64\mingw64\bin;%path:C:\msys64\mingw64\bin;=% -path=%~dp0tools\vcpkg;%path% :: find generic tools if not defined CMD_NINJA call %~dp0tools\find-tools.bat +if not exist %~dp0tools\vcpkg\bootstrap-vcpkg.bat ( + "%CMD_GIT%" submodule update --init +) + +if errorlevel 1 ( + echo ERROR submodule update %errorlevel% + exit /b 1 +) + +if not exist %~dp0tools\vcpkg\vcpkg.exe ( + call %~dp0tools\vcpkg\bootstrap-vcpkg.bat +) + +path=%~dp0tools\vcpkg;%path% + @rem create output directory, all executables will be placed here. set OUTDIR=%~dp0%platform%\%configuration% mkdir %OUTDIR% > NUL 2>&1 diff --git a/build-sln.bat b/build-sln.bat index 42e42eae2a..8034af416e 100644 --- a/build-sln.bat +++ b/build-sln.bat @@ -1,4 +1,4 @@ -@echo off +@echo on set platform=%1 set configuration=%2 @@ -25,6 +25,19 @@ if not defined CMD_MSBUILD ( exit /b 1 ) +if not exist %~dp0tools\vcpkg\bootstrap-vcpkg.bat ( + "%CMD_GIT%" submodule update --init +) + +if errorlevel 1 ( + echo ERROR submodule update %errorlevel% + exit /b 1 +) + +if not exist %~dp0tools\vcpkg\vcpkg.exe ( + call %~dp0tools\vcpkg\bootstrap-vcpkg.bat +) + set SLN_FILE=sakura.sln @rem https://www.appveyor.com/docs/environment-variables/