vcpkg: Classic vs Manifest Mode
vcpkg is Microsoft's open-source C/C++ package manager. Where Conan is a general framework with recipes and remotes, vcpkg is a curated collection: one Git repository holds the tool's scripts and more than 2,500 ports (build recipes), and every port is tested to build together with every other port at each commit. You get a consistent set of libraries instead of choosing versions one by one.
| Term | Meaning |
|---|---|
| port | a folder ports/<name>/ with vcpkg.json (metadata) and portfile.cmake (how to build) |
| triplet | the target configuration, e.g. x64-linux, x64-windows, arm64-osx (Triplets) |
| baseline | a commit of the vcpkg repository that fixes every port's version (Baselines) |
| manifest | your project's vcpkg.json, listing what it needs |
| binary cache | zip files of built packages, keyed by an ABI hash (Binary Caching) |
| registry | a source of ports; the built-in one is the vcpkg repository itself (Custom Registries) |
Getting vcpkg
vcpkg is a Git clone plus a small executable that a bootstrap script downloads:
bash
git clone https://github.com/microsoft/vcpkg.git ~/vcpkg
~/vcpkg/bootstrap-vcpkg.sh # bootstrap-vcpkg.bat on Windows
export VCPKG_ROOT=~/vcpkg
export PATH="$VCPKG_ROOT:$PATH"Visual Studio 2022 and newer also ship a copy (in the Developer Command Prompt), and GitHub's hosted runners have one preinstalled. Our container has a clone at /opt/vcpkg, pinned to the 2026.10.16 release tag:
bash · try it yourself
vcpkg version | head -1
echo "VCPKG_ROOT=$VCPKG_ROOT"
ls "$VCPKG_ROOT" | grep -vE '\.(md|txt|yml|nix|bat)