This repository contains CMake scripts for fetching and compiling various libraries on-demand. The repository is kept lightweight to be integrated into other projects by adding it as a git submodule.
The scripts are tested by examples in CMake Library Tests repository.
Execute the following in your project root directory to add cmake-libs
directory to your project:
git submodule add git@github.com:mikucionisaau/cmake-libs.git
Then in your CMakeLists.txt
file add one or several of the following commands:
include(cmake-libs/sanitizers.cmake) # Compiler options to enable sanitizers
include(cmake-libs/doctest.cmake) # Fetches doctest unit testing framework
include(cmake-libs/benchmark.cmake) # Fetches Google Benchmark framework
Visit CMake Library Tests to see features and simple use cases.
The following libraries are supported:
- sanitizers compiler sanitizer options.
- doctest: doctest unit testing framework.
- benchmark: Google Micro-Benchmarking framework.