From 6229de5402bf7d20064e1ff20ea120c94e975545 Mon Sep 17 00:00:00 2001 From: Roberto Scolaro Date: Tue, 19 Mar 2024 11:17:54 +0000 Subject: [PATCH] new(ci): add sccache support Signed-off-by: Roberto Scolaro --- .github/workflows/e2e_ci.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/e2e_ci.yml b/.github/workflows/e2e_ci.yml index 0c21efd754..c663706377 100644 --- a/.github/workflows/e2e_ci.yml +++ b/.github/workflows/e2e_ci.yml @@ -35,6 +35,7 @@ jobs: clang-14 llvm-14 \ git \ clang \ + ccache \ llvm \ pkg-config \ autoconf \ @@ -73,11 +74,18 @@ jobs: run: | sudo apt install -y --no-install-recommends linux-headers-$(uname -r) gcc-multilib g++-multilib + - name: Run sccache-cache + uses: mozilla-actions/sccache-action@v0.0.3 + - name: Build e2e tests 🏗️ + env: + SCCACHE_GHA_ENABLED: "true" run: | mkdir -p build cd build && \ cmake \ + -DCMAKE_C_COMPILER_LAUNCHER=sccache \ + -DCMAKE_CXX_COMPILER_LAUNCHER=sccache \ -DBUILD_BPF=ON \ -DUSE_BUNDLED_DEPS=ON \ -DUSE_ASAN=ON \ @@ -97,7 +105,7 @@ jobs: id: cache with: path: build - key: build-${{ matrix.arch }}-${{ github.run_id }} + key: build-e2e-${{ matrix.arch }}-${{ github.run_id }} test-e2e: name: test-e2e-${{ matrix.arch }}-${{ matrix.driver.name }} 😇 (bundled_deps) @@ -114,8 +122,8 @@ jobs: uses: actions/cache/restore@v3 with: path: build - key: build-${{ matrix.arch }}-${{ github.run_id }} - restore-keys: build- + key: build-e2e-${{ matrix.arch }}-${{ github.run_id }} + restore-keys: build-e2e- - name: Fix kernel mmap rnd bits # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with