Skip to content

Latest commit

 

History

History
45 lines (30 loc) · 962 Bytes

File metadata and controls

45 lines (30 loc) · 962 Bytes
description Build C++ projects with CMake

Build Command

Build the project using CMake presets.

Instructions

  1. Check for CMake presets:
cmake --list-presets
  1. If presets exist, use them:
cmake --preset <preset-name>
cmake --build --preset <preset-name>
  1. If no presets, use standard out-of-source build:
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build
  1. For specific compilers:
Compiler CMake Generator
MSVC -G "Visual Studio 17 2022"
GCC -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++
Clang -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++

Output

Build artifacts will be in the build/ directory (or as specified by presets).


Based on Vinnie Falco's build command from cppalliance/coro-io-context