Sections[tools]

Tooling

Compilers, build systems, package managers, editors, debuggers, analyzers and CI, for C++ developers deciding what to install and what to pay for.

Clause
6 of 8
Answers
9, newest first
Written for
C++17, C++23
Written by

C++ has no single official toolchain: three major compilers, several build systems and competing package managers, each with its own flags and defaults. This section covers everything around the code, from the compiler to the CI run. Toolchain lists what a working team would install.

In this section

  • GCC, Clang and MSVC
  • CMake and other build systems
  • Conan and vcpkg
  • IDEs and editors
  • Debuggers
  • Static analyzers and linters
  • Sanitizers and fuzzing
  • Testing frameworks
  • Continuous integration
  • Build caching and distributed builds
  • AI coding assistants for C++
  • Formatting and documentation tools

Answers in Tooling 9, newest first

  1. Best C++ IDE: which to install on Windows, Mac or Linux

    The best C++ IDE for Windows, Mac or Linux: Visual Studio, VS Code, CLion, Xcode or Qt Creator, where each runs, what is free, and IDE vs compiler.

    §6.36 min readC++17

    written for C++17

  2. clang-format: format C++ with a .clang-format file

    clang-format lays out C++ code in one command: where the .clang-format file goes, the seven styles, the options people change and a CI check.

    §6.48 min readC++17

    written for C++17

  3. What is CMake? A build system generator, explained

    What is CMake? A build system generator, shown with a CMakeLists.txt that builds, the two commands, cmake clean, CMake vs Make, a library and Release.

    §6.58 min readC++17

    written for C++17

  4. Compile C++ with GCC: g++ commands and flags

    How to compile C++ with GCC: the g++ command, choosing the C++ standard, the flags a beginner needs, several files, installing GCC and the common errors.

    §6.67 min readC++17

    written for C++17

  5. Compiler vs interpreter: what is the difference?

    Compiler vs interpreter: the same program run both ways in C++ and Python, when each one finds an error, why Python is both, and what JIT compilation is.

    §6.77 min readC++17

    written for C++17

  6. C++ header files: what goes in them, and what must not

    What goes in a C++ header file and what in the .cpp, how to build the two, include guards or #pragma once, and the multiple definition error.

    §6.87 min readC++17

    written for C++17

  7. What does a compiler do? C++ source to program

    What does a compiler do? It turns C++ source into a program in four stages, each run here on a real file, with the commands and the three kinds of error.

    §6.97 min readC++17

    written for C++17

  8. clang-tidy: run it, configure it, pick the checks

    clang-tidy from the first run to CI: one file, a whole project with compile_commands.json, a starter .clang-tidy and the checks to turn on first.

    §6.116 min readC++17

    written for C++17

  9. Clang vs GCC: what differs for a C++ project

    Clang vs GCC for C++: default standard, libstdc++ or libc++, C++26 features and warnings, each built on GCC 16.2 and Clang 23.1, then tools and which to pick.

    §6.214 min readC++23

    written for C++23