- Fixed malformed regular expression for filtering files.
- Fixed incorrect C++/C standard detection.
- Add FOLDER and PROJECT_LABEL support.
- Fix order of flags, includes and defines causing issues.
- Fix multiple spaces causing flags to be treated as files.
- Upgrade to string(JSON) in many places.
- Make GLOBAL the default and remove the option.
- 'compile_commands.json' is now generated in less time, with way more content.
- Removed compiler restrictions which had no actual effect on users.
- Added very basic clang-tidy support for all compilers that can handle it.
For an unknown reason, multiple set() calls in a row with the same variable override previous attempts to set things, despite using the same variable. This completely breaks generated output as barely any include directories will be set.
Adds support for clang-tidy by the use of a manually generated compile command database. This is likely not full functional yet, so more tests might have to be done on different platforms and compilers.
# clang_format([DEPENDENCY] [GLOBAL] [REGEX "..."] TARGETS "..." ["..."])
Adds a clang-format call target for each of the specified targets, which optionally filters files using a special regex (defaults to .c, .cpp, .h, .hpp), with an optional global target, and an optional dependency addition to ensure that formatting is applied before building any of the targets.
* DEPENDENCY: Add a dependency to each of the targets onto the clang-format target, to ensure that formatting is applied at build time.
* GLOBAL: Create a global target and add the clang-format target as a dependency to it.
* REGEX "...": Filter file by a custom regular expression instead of the default filter. Must be a regular expression.
* TARGETS "...": Specifies the targets that clang-format is used for.