diff options
author | Ray Molenkamp <github@lazydodo.com> | 2020-04-20 21:51:43 +0300 |
---|---|---|
committer | Ray Molenkamp <github@lazydodo.com> | 2020-04-20 21:51:43 +0300 |
commit | 55a2682348df94d0ff2f57d786b7a557312d0345 (patch) | |
tree | c79466cc4bd00ce1469c96205723ac25d86d7968 /build_files/windows/configure_msbuild.cmd | |
parent | 9618bd9202a7f4a024895da443d8e053debe6b4a (diff) |
Windows: Add sccache support.
sccache [1] is one of the few ccache like solutions that will
work on windows.
sccache support can be enabled with the `WITH_WINDOWS_SCCACHE`
cmake option however it will only will work with ninja as the
build system, msbuild is not supported currently.
Advanced option, developes are expected to obtain and configure
sccache on their own.
```
Full build no cache 1428.90s (100.00%)
Full build cached 434.34s ( 30.40%)
```
[1] https://github.com/mozilla/sccache
Reviewed By: nicholas_rishel, Brecht
Differential Revision: https://developer.blender.org/D7466
Diffstat (limited to 'build_files/windows/configure_msbuild.cmd')
-rw-r--r-- | build_files/windows/configure_msbuild.cmd | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/build_files/windows/configure_msbuild.cmd b/build_files/windows/configure_msbuild.cmd index 3c1194011cd..4956f1e3ea1 100644 --- a/build_files/windows/configure_msbuild.cmd +++ b/build_files/windows/configure_msbuild.cmd @@ -2,6 +2,11 @@ set BUILD_GENERATOR_POST= set BUILD_PLATFORM_SELECT= set MSBUILD_PLATFORM=x64 +if "%BUILD_WITH_SCCACHE%"=="1" ( + echo sccache is only supported with ninja as the build system. + exit /b 1 +) + if "%WITH_CLANG%"=="1" ( set CLANG_CMAKE_ARGS=-T"llvm" if "%WITH_ASAN%"=="1" ( |