Add build cache

This commit is contained in:
qurious-pixel 2025-06-09 12:09:02 -07:00 committed by GitHub
parent 3450ab657f
commit 439aa64f3f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -326,7 +326,7 @@ jobs:
name: RPCS3 FreeBSD name: RPCS3 FreeBSD
runs-on: ubuntu-latest runs-on: ubuntu-latest
env: env:
CCACHE_DIR: /tmp/ccache_dir CCACHE_DIR: ${{ github.workspace }}/ccache
CI_HAS_ARTIFACTS: true CI_HAS_ARTIFACTS: true
ARTDIR: "/root/artifacts" ARTDIR: "/root/artifacts"
RELEASE_MESSAGE: "/rpcs3/GitHubReleaseMessage.txt" RELEASE_MESSAGE: "/rpcs3/GitHubReleaseMessage.txt"
@ -338,10 +338,26 @@ jobs:
uses: actions/checkout@main uses: actions/checkout@main
with: with:
fetch-depth: 0 fetch-depth: 0
- name: Restore Build Ccache
uses: actions/cache/restore@main
id: restore-build-ccache
with:
path: ${{ env.CCACHE_DIR }}
key: FreeBSD-ccache-${{github.run_id}}
restore-keys: FreeBSD-ccache-
- name: FreeBSD build - name: FreeBSD build
id: root id: root
uses: vmactions/freebsd-vm@v1 uses: vmactions/freebsd-vm@v1
with: with:
envs: 'QT_VER_MAIN LLVM_COMPILER_VER' envs: 'QT_VER_MAIN LLVM_COMPILER_VER CCACHE_DIR'
usesh: true usesh: true
run: .ci/install-freebsd.sh && .ci/build-freebsd.sh run: .ci/install-freebsd.sh && .ci/build-freebsd.sh
- name: Save Build Ccache
if: github.ref == 'refs/heads/master'
uses: actions/cache/save@main
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ steps.restore-build-ccache.outputs.cache-primary-key }}