From 80408f704e8442a27f6dca96c41f1d3bded7ce52 Mon Sep 17 00:00:00 2001 From: embeddedt <42941056+embeddedt@users.noreply.github.com> Date: Mon, 24 Jan 2022 10:42:54 -0500 Subject: [PATCH] ci attempt to speed up cross tests --- .github/workflows/ccpp.yml | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ccpp.yml b/.github/workflows/ccpp.yml index 7424a4b05..a485559ca 100644 --- a/.github/workflows/ccpp.yml +++ b/.github/workflows/ccpp.yml @@ -55,6 +55,12 @@ jobs: steps: - uses: actions/checkout@v2.1.0 + - name: Setup cache + uses: actions/cache@v2 + with: + path: | + ~/.ccache + key: lvgl_ci_cross_test_ccache_${{ matrix.arch }} - uses: uraimo/run-on-arch-action@v2.1.1 name: Run tests id: build @@ -67,11 +73,20 @@ jobs: # The shell to run commands with in the container shell: /bin/bash + + # Create cached/volume directories on host + setup: | + mkdir -p ~/.ccache + + # Mount cached directories in the container for faster builds + dockerRunArgs: | + --volume "${HOME}/.ccache:/root/.ccache" install: | apt-get update -y - apt-get install -y gcc python3 libpng-dev ruby-full gcovr cmake - apt-get install -y build-essential + apt-get install build-essential ccache python3 libpng-dev ruby-full gcovr cmake -q -y + /usr/sbin/update-ccache-symlinks + echo 'export PATH="/usr/lib/ccache:$PATH"' | tee -a ~/.bashrc run: | - env ASAN_OPTIONS=detect_leaks=0 python3 tests/main.py --report test + env ASAN_OPTIONS=detect_leaks=0 python3 tests/main.py test