Ccache setup
The goal is to speed up recompilation using ccache. Ccache is a tool that speeds up recompilation of C/C++ code. It does this by caching the results of previous compilations. When you recompile code, ccache checks if it has already compiled the same code with the same compiler flags. If so, it uses the cached result instead of recompiling.
This commit is contained in:
parent
3dc2058400
commit
cfcd6e22bb
3 changed files with 20 additions and 1 deletions
|
|
@ -20,6 +20,17 @@ project("ParadisEO"
|
|||
## Language
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
||||
## ccache
|
||||
find_program(CCACHE_PROGRAM ccache)
|
||||
|
||||
if (CCACHE_PROGRAM)
|
||||
message(NOTICE "-- ccache is enabled (found here: ${CCACHE_PROGRAM})")
|
||||
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE "\"${CCACHE_PROGRAM}\"")
|
||||
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK "\"${CCACHE_PROGRAM}\"")
|
||||
else ()
|
||||
message(NOTICE "-- ccache has not been found")
|
||||
endif ()
|
||||
|
||||
|
||||
######################################################################################
|
||||
### 2) Check dependencies
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue