Add tools.cmake (#14)

* add sanitizer support. closes #13.

* add comment

* add tools.cmake

* document tools

* cleanup

* add tools to feature list
This commit is contained in:
Lars Melchior 2020-04-16 13:01:52 +02:00 committed by GitHub
parent 62469ec741
commit cec2e8cf4d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 51 additions and 5 deletions

View file

@ -21,6 +21,7 @@ This template is the result of learnings from many previous projects and should
- Code formatting enforced by [clang-format](https://clang.llvm.org/docs/ClangFormat.html) via [Format.cmake](https://github.com/TheLartians/Format.cmake)
- Reproducible dependency management via [CPM.cmake](https://github.com/TheLartians/CPM.cmake)
- Installable target with versioning information via [PackageProject.cmake](https://github.com/TheLartians/PackageProject.cmake)
- Support for [sanitizer tools and more](#additional-tools)
## Usage
@ -76,6 +77,14 @@ cmake --build build/test --target fix-format
See [Format.cmake](https://github.com/TheLartians/Format.cmake) for more options.
### Additional tools
The project includes an [tools.cmake](cmake/tools.cmake) file that can be used to import additional tools on-demand through CMake configuration arguments.
The following are currently supported.
- `-DUSE_SANITIZER=<Address | Memory | MemoryWithOrigins | Undefined | Thread | Leak | 'Address;Undefined'>`
- `-DUSE_CCACHE=<YES | NO>`
## FAQ
> Can I use this for header-only libraries?