server/vs2019-build.bat

19 lines
569 B
Batchfile

@ECHO OFF
SET CMAKE_ROOT=%ProgramFiles%\CMake
SET VSVERSION=16
SET SRCDIR=%CD%
REM CD ..
REM SET ERESSEA=%CD%
REM CD %SRCDIR%
SET CMAKE_MODULES="%CMAKE_ROOT%\share\cmake-3.19\Modules"
IF exist build-vs%VSVERSION% goto HAVEDIR
mkdir build-vs%VSVERSION%
:HAVEDIR
cd build-vs%VSVERSION%
IF NOT EXIST CMakeCache.txt GOTO NOCACHE
DEL CMakeCache.txt
:NOCACHE
"%CMAKE_ROOT%\bin\cmake.exe" -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake -A x64 -G "Visual Studio %VSVERSION%" -DCMAKE_MODULE_PATH="%CMAKE_MODULES%" -DCMAKE_SUPPRESS_REGENERATION=TRUE ..
PAUSE