Add basic windows build script
authoralfadur
Mon, 15 Oct 2018 22:22:51 +0300
changeset 13923 4d63acb2b978
parent 13922 3a0d09a31f5f
child 13924 a140f28decc4
Add basic windows build script
tools/build_vcpkg_basic.bat
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tools/build_vcpkg_basic.bat	Mon Oct 15 22:22:51 2018 +0300
@@ -0,0 +1,37 @@
+@echo off
+::edit these variables if necessary
+set BUILD_TYPE="Debug"
+::set if vcpkg is not on path
+set VCPKG_PATH=%VCPKG_ROOT%
+::set if CMake is not on path
+set CMAKE_PATH=
+::set if FPC is not on path
+set PASCAL_PATH=
+
+:setup
+set CURRDIR="%CD%"
+cd %CURRDIR%\..\
+
+set PATH=%PASCAL_PATH%;%VCPKG_PATH%;%CMAKE_PATH%;%PATH%
+
+echo Running cmake...
+set ERRORLEVEL=
+
+cmake . -DCMAKE_TOOLCHAIN_FILE="%VCPKG_PATH%\scripts\buildsystems\vcpkg.cmake" -G"NMake Makefiles" -DNOPNG=1 -DNOSERVER=1 -DNOVIDEOREC=1 -DCMAKE_BUILD_TYPE="%BUILD_TYPE%"
+
+if %ERRORLEVEL% NEQ 0 goto exitpoint
+
+echo Configuration completed successfully
+
+echo Building...
+set ERRORLEVEL=
+
+nmake
+
+if %ERRORLEVEL% NEQ 0 goto exitpoint
+
+echo Build completed successfully
+
+:exitpoint
+cd %CURRDIR%
+pause