mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-07 18:50:48 +02:00
smoke-test, os-check: pin CCACHE_DIR to the cached path
The two jobs that manage their ccache cache manually rely on ccache's XDG default (~/.cache/ccache) matching the actions/cache path. That holds today, but nothing enforces it: a later change that sets CCACHE_DIR (e.g. adopting the ccache-setup composite, which uses ~/.ccache) would silently decouple the build's cache from the saved/restored directory. Pin CCACHE_DIR explicitly to the cached path so the pairing is visible and cannot drift.
This commit is contained in:
@@ -75,6 +75,12 @@ jobs:
|
||||
- name: Allow unprivileged user namespaces (for bwrap)
|
||||
run: sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0 || true
|
||||
|
||||
# ccache's default cache dir (XDG ~/.cache/ccache) is what the
|
||||
# actions/cache step below saves; pin it explicitly so the two
|
||||
# cannot drift apart (e.g. if a later change sets CCACHE_DIR).
|
||||
- name: Pin ccache directory
|
||||
run: echo "CCACHE_DIR=$HOME/.cache/ccache" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Restore ccache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
|
||||
@@ -98,6 +98,13 @@ jobs:
|
||||
if: steps.merge_check.outputs.skip != 'true'
|
||||
run: sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0 || true
|
||||
|
||||
# ccache's default cache dir (XDG ~/.cache/ccache) is what the
|
||||
# actions/cache step below saves; pin it explicitly so the two
|
||||
# cannot drift apart (e.g. if a later change sets CCACHE_DIR).
|
||||
- name: Pin ccache directory
|
||||
if: steps.merge_check.outputs.skip != 'true'
|
||||
run: echo "CCACHE_DIR=$HOME/.cache/ccache" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Restore ccache
|
||||
if: steps.merge_check.outputs.skip != 'true'
|
||||
uses: actions/cache@v4
|
||||
|
||||
Reference in New Issue
Block a user