Fix sccache

This commit is contained in:
momo5502
2025-05-29 09:58:51 +02:00
parent 5041bab9f8
commit 5022e3049a
3 changed files with 14 additions and 13 deletions

View File

@@ -1,15 +1,8 @@
include_guard()
if(CMAKE_GENERATOR STREQUAL "Ninja")
find_program(SCCACHE sccache REQUIRED)
find_program(SCCACHE sccache)
if (SCCACHE)
set(CMAKE_C_COMPILER_LAUNCHER ${SCCACHE})
set(CMAKE_CXX_COMPILER_LAUNCHER ${SCCACHE})
set(CMAKE_MSVC_DEBUG_INFORMATION_FORMAT Embedded)
if(POLICY CMP0141)
cmake_policy(SET CMP0141 NEW)
endif()
endif()
if (SCCACHE)
set(CMAKE_C_COMPILER_LAUNCHER ${SCCACHE})
set(CMAKE_CXX_COMPILER_LAUNCHER ${SCCACHE})
endif()