C++ examples with Boost v1.89.0.
This repository is structured as a CMake Monorepo. It uses vcpkg (Manifest Mode) for dependency management and CMake Presets for a unified build workflow on Linux.
Before building, ensure you have the following installed:
- C++ Compiler (GCC or Clang)
- CMake (v3.20 or newer required for Presets)
- Ninja (Recommended for build speed) or Make
- pkg-config (required by some vcpkg ports)
- Common build utilities used by vcpkg (git, curl, zip/unzip, tar)
- vcpkg
Run the following commands from the project root:
git clone https://github.com/microsoft/vcpkg.git vcpkg
cd vcpkg
./bootstrap-vcpkg.sh -disableMetricsThen set the environment variables:
export VCPKG_ROOT="$(pwd)"
export PATH="$VCPKG_ROOT:$PATH"The commands below are executed from the root of the repository.
This step reads vcpkg.json, downloads and compiles dependencies (Boost, Protobuf, etc.), and generates the build files.
cmake --preset vcpkg-debugcmake --build --preset vcpkg-debugcmake --build --preset vcpkg-debug --target <target_name>cmake --build --preset vcpkg-release