TheLartians / ModernCppStarter

🚀 Kick-start your C++! A template for modern C++ projects using CMake, CI, code coverage, clang-format, reproducible dependency management and much more.
https://thelartians.github.io/ModernCppStarter
The Unlicense
4.45k stars 388 forks source link

USE_<TOOL> defines cause a warning #57

Closed friendlyanon closed 4 years ago

friendlyanon commented 4 years ago

Steps to reproduce:

Expected output:

No warnings.

Actual output:

CMake Warning:
  Manually-specified variables were not used by the project:

    USE_CCACHE
TheLartians commented 4 years ago

Good catch! When the tools were originally written, they were intended to be included by the main library and needed to be excluded when used as a third-party dependency. As we are now only importing tools from subprojects, the restriction should not be necessary anymore.

Edit: see below

TheLartians commented 4 years ago

On second thought, the flags we are setting should be scoped for the whole project, so the best solution would be to simply include the tools from the "all" subproject as well.