diff --git a/CMakeLists.txt b/CMakeLists.txt index 9a996686f90cde6ab2e3860a8d36d43e1e41ed82..2da13ecc73e449129302fec27dc5cb5ff91473d7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -30,6 +30,7 @@ endif() option(OGS_USE_CONAN "Should Conan package manager be used?" ON) set(OGS_CONAN_BUILD "missing" CACHE STRING "Possible values: all, missing, \ never or list of libs to build") +option(OGS_DISABLE_CCACHE "Disables ccache compiler cache." OFF) # Third-party libraries, names come from Conan package names set(OGS_LIBS diff --git a/scripts/cmake/CCacheSetup.cmake b/scripts/cmake/CCacheSetup.cmake index c5ba97a4612c3ae57b4dacb7823a721ba38fabb1..e00f95edbcc288921570188c360610bd3515e1bd 100644 --- a/scripts/cmake/CCacheSetup.cmake +++ b/scripts/cmake/CCacheSetup.cmake @@ -1,4 +1,4 @@ -if(NOT CCACHE_TOOL_PATH) +if(NOT CCACHE_TOOL_PATH OR OGS_DISABLE_CCACHE) return() endif()