We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8195bdf commit 68ac4ffCopy full SHA for 68ac4ff
src/StaticAnalyzers.cmake
@@ -23,7 +23,21 @@ macro(enable_cppcheck)
23
endmacro()
24
25
macro(enable_clang_tidy)
26
- find_program(CLANGTIDY clang-tidy)
+ # https://github.com/ejfitzgerald/clang-tidy-cache
27
+ find_program(
28
+ CLANGTIDY_CACHE
29
+ NAMES "clang-tidy-cache"
30
+ "clang-tidy-cache-windows-amd64"
31
+ "clang-tidy-cache-linux-amd64"
32
+ "clang-tidy-cache-darwin-amd64")
33
+ if(CLANGTIDY_CACHE)
34
+ # use clang-tidy-cache if found
35
+ set($ENV{CLANG_TIDY_CACHE_BINARY} ${CLANGTIDY_CACHE})
36
+ set(CLANGTIDY ${CLANGTIDY_CACHE})
37
+ else()
38
+ # otherwise use clang-tidy directly
39
+ find_program(CLANGTIDY clang-tidy)
40
+ endif()
41
if(CLANGTIDY)
42
if(NOT
43
CMAKE_CXX_COMPILER_ID
0 commit comments