mirror of
https://github.com/OpenMW/openmw.git
synced 2026-01-30 11:48:27 +00:00
switch to sccache
This commit is contained in:
parent
3723fb5773
commit
72bd3a6f66
2 changed files with 14 additions and 12 deletions
|
|
@ -352,7 +352,7 @@ variables: &tests-targets
|
|||
- choco source add -n=openmw-proxy -s="https://repo.openmw.org/repository/Chocolatey/" --priority=1
|
||||
- choco install git --force --params "/GitAndUnixToolsOnPath" -y
|
||||
- choco install 7zip -y
|
||||
- choco install ccache -y
|
||||
- choco install sccache -y
|
||||
- choco install cmake.install --installargs 'ADD_CMAKE_TO_PATH=System' -y
|
||||
- choco install vswhere -y
|
||||
- choco install ninja -y
|
||||
|
|
@ -375,10 +375,11 @@ variables: &tests-targets
|
|||
- $time = (Get-Date -Format "HH:mm:ss")
|
||||
- echo ${time}
|
||||
- echo "started by ${GITLAB_USER_NAME}"
|
||||
- $env:CCACHE_BASEDIR = Get-Location
|
||||
- $env:CCACHE_DIR = "$(Get-Location)\ccache"
|
||||
- New-Item -Type Directory -Force -Path $env:CCACHE_DIR
|
||||
- ccache -z -M $CCACHE_SIZE
|
||||
- $env:SCCACHE_BASEDIR = Get-Location
|
||||
- $env:SCCACHE_DIR = "$(Get-Location)\ccache"
|
||||
- New-Item -Type Directory -Force -Path $env:SCCACHE_DIR
|
||||
- sccache --show-stats
|
||||
- sccache --start-server
|
||||
- sh CI/before_script.msvc.sh -c $config -p Win64 -v 2019 -k -V -N -b -t -C
|
||||
- cd MSVC2019_64_Ninja
|
||||
- .\ActivateMSVC.ps1
|
||||
|
|
@ -393,16 +394,17 @@ variables: &tests-targets
|
|||
}
|
||||
- 7z a -tzip "..\..\$(Make-SafeFileName("OpenMW_MSVC2019_64_${package}_${config}_${CI_COMMIT_REF_NAME}.zip"))" '*'
|
||||
- if ($executables) { foreach ($exe in $executables.Split(',')) { & .\$exe } }
|
||||
- sccache --show-stats
|
||||
after_script:
|
||||
- Copy-Item C:\ProgramData\chocolatey\logs\chocolatey.log
|
||||
cache:
|
||||
key: ninja-v2
|
||||
paths:
|
||||
- ccache
|
||||
- sccache
|
||||
- deps
|
||||
- MSVC2019_64_Ninja/deps/Qt
|
||||
variables:
|
||||
CCACHE_SIZE: 2G
|
||||
SCCACHE_SIZE: 2G
|
||||
artifacts:
|
||||
when: always
|
||||
paths:
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ VERBOSE=""
|
|||
STRIP=""
|
||||
SKIP_DOWNLOAD=""
|
||||
SKIP_EXTRACT=""
|
||||
USE_CCACHE=""
|
||||
USE_SCCACHE=""
|
||||
KEEP=""
|
||||
UNITY_BUILD=""
|
||||
VS_VERSION=""
|
||||
|
|
@ -102,7 +102,7 @@ while [ $# -gt 0 ]; do
|
|||
SKIP_EXTRACT=true ;;
|
||||
|
||||
C )
|
||||
USE_CCACHE=true ;;
|
||||
USE_SCCACHE=true ;;
|
||||
k )
|
||||
KEEP=true ;;
|
||||
|
||||
|
|
@ -149,7 +149,7 @@ Options:
|
|||
For mutli-config generators, this is ignored, and all configurations are set up.
|
||||
For single-config generators, several configurations can be set up at once by specifying -c multiple times.
|
||||
-C
|
||||
Use ccache.
|
||||
Use sccache.
|
||||
-d
|
||||
Skip checking the downloads.
|
||||
-e
|
||||
|
|
@ -508,8 +508,8 @@ if ! [ -z $UNITY_BUILD ]; then
|
|||
add_cmake_opts "-DOPENMW_UNITY_BUILD=True"
|
||||
fi
|
||||
|
||||
if ! [ -z $USE_CCACHE ]; then
|
||||
add_cmake_opts "-DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache"
|
||||
if ! [ -z $USE_SCCACHE ]; then
|
||||
add_cmake_opts "-DCMAKE_C_COMPILER_LAUNCHER=sccache -DCMAKE_CXX_COMPILER_LAUNCHER=sccache"
|
||||
fi
|
||||
|
||||
echo
|
||||
|
|
|
|||
Loading…
Reference in a new issue