diff options
author | Eric Engestrom <[email protected]> | 2019-02-12 16:59:27 +0000 |
---|---|---|
committer | Eric Engestrom <[email protected]> | 2019-02-19 10:09:51 +0000 |
commit | 23b485c920a64ba302a908e7b13c89bc7a76565e (patch) | |
tree | eda26fae8b24edfee1b38c6511c801b90f55c311 /.gitlab-ci.yml | |
parent | dbe3af67a47ba929c89e9482fbc9396fc1114d93 (diff) |
gitlab-ci: use ccache to speed up builds
Signed-off-by: Eric Engestrom <[email protected]>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r-- | .gitlab-ci.yml | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9e1a32f7a0a..7e4a5f1d8d6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,10 +16,13 @@ # The format of the tag is "%Y-%m-%d-${counter}" where ${counter} stays # at "01" unless you have multiple updates on the same day :) variables: - UBUNTU_TAG: 2019-01-31-01 + UBUNTU_TAG: 2019-02-12-01 UBUNTU_IMAGE: "$CI_REGISTRY_IMAGE/ubuntu:$UBUNTU_TAG" UBUNTU_IMAGE_MAIN: "registry.freedesktop.org/mesa/mesa/ubuntu:$UBUNTU_TAG" +cache: + paths: + - ccache stages: - containers-build @@ -63,10 +66,21 @@ containers:ubuntu: artifacts: when: on_failure untracked: true + # Use ccache transparently, and print stats before/after + before_script: + - export PATH="/usr/lib/ccache:$PATH" + - export CCACHE_BASEDIR="$PWD" + - export CCACHE_DIR="$PWD/ccache" + - export CCACHE_COMPILERCHECK=content + - ccache --zero-stats || true + - ccache --show-stats || true + after_script: + - export CCACHE_DIR="$PWD/ccache" + - ccache --show-stats .meson-build: extends: .build - before_script: + script: # We need to control the version of llvm-config we're using, so we'll # generate a native file to do so. This requires meson >=0.49 - if test -n "$LLVM_VERSION"; then @@ -88,7 +102,6 @@ containers:ubuntu: -D vulkan-drivers=${VULKAN_DRIVERS:-[]} - cd _build - meson configure - script: - ninja -j4 - ninja test @@ -96,7 +109,7 @@ containers:ubuntu: extends: .build variables: MAKEFLAGS: "-j4" - before_script: + script: - if test -n "$LLVM_VERSION"; then export LLVM_CONFIG="llvm-config-${LLVM_VERSION}"; fi @@ -112,7 +125,6 @@ containers:ubuntu: --with-gallium-drivers=$GALLIUM_DRIVERS --with-vulkan-drivers=$VULKAN_DRIVERS --disable-llvm-shared-libs - script: - make - eval $MAKE_CHECK_COMMAND |