Setup on Windows
Garvan compiles on Windows with MSVC 2019/2022 or with MinGW-w64. The simplest workflow uses vcpkg for the dependencies.
Requirements
- Visual Studio 2019 or later, with the "Desktop development with C++" workload.
- CMake 3.20 (included with Visual Studio).
- vcpkg, or pre-built binaries for Asio, OpenSSL and the database clients.
Using vcpkg
git clone https://github.com/microsoft/vcpkg.git
.\vcpkg\bootstrap-vcpkg.bat
.\vcpkg\vcpkg install asio openssl zlib libpqxx sqlite3
Compiling with MSVC
Configure your project with the vcpkg toolchain:
cmake -S . -B build ^
-DCMAKE_TOOLCHAIN_FILE=/scripts/buildsystems/vcpkg.cmake
cmake --build build --config Release
Warning
Garvan currently does not ship a precompiled libgarvan.lib for MSVC. On Windows you should build Garvan from source so the C++ ABI matches your toolchain.