Technical requirements
As with the previous chapters, the examples are tested with CMake 3.24 and run on any of the following compilers:
- GCC 9 or newer
- Clang 12 or newer
- MSVC 19 or newer
Some of the examples for code coverage, sanitizers, and static code analysis require GCC or Clang to run and will not work with MSVC. To run Clang on Windows, take a look at Chapter 9, Creating Reproducible Build Environments, where toolchain files are introduced. Some examples need the Catch2 unit testing suite installed to compile. Some examples pull dependencies from various online locations, so an internet connection is required as well.
In addition to a working compiler, the following software is used for the examples:
Gcov
,Gcovr
, andlcov
for the Linux examples on code coverageOpencppcoverage
for the Windows examples on code coverageClang-tidy
,Cppcheck
,Cpplint
, andinclude-what-you-use
for the examples on static code analyzers
All examples...