added initial usage of `ccache` in the CI (#4408)

This commit is contained in:
Oliver Stöneberg 2022-08-27 15:06:16 +02:00 committed by GitHub
parent d26eb3903e
commit 732282fe06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 1 deletions

View File

@ -16,6 +16,11 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: scriptcheck-${{ runner.os }}
- name: Cache Cppcheck - name: Cache Cppcheck
uses: actions/cache@v2 uses: actions/cache@v2
with: with:
@ -24,6 +29,7 @@ jobs:
- name: build cppcheck - name: build cppcheck
run: | run: |
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
make -j$(nproc) -s make -j$(nproc) -s
strip -s ./cppcheck strip -s ./cppcheck

View File

@ -18,6 +18,11 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: selfcheck-${{ runner.os }}
- name: Cache Qt ${{ env.QT_VERSION }} - name: Cache Qt ${{ env.QT_VERSION }}
id: cache-qt id: cache-qt
uses: actions/cache@v1 # not v2! uses: actions/cache@v1 # not v2!
@ -35,7 +40,7 @@ jobs:
# TODO: cache this - perform same build as for the other self check # TODO: cache this - perform same build as for the other self check
- name: Self check (build) - name: Self check (build)
run: | run: |
make clean export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
make -j$(nproc) -s CXXFLAGS="-O2 -w" MATCHCOMPILER=yes make -j$(nproc) -s CXXFLAGS="-O2 -w" MATCHCOMPILER=yes
- name: CMake - name: CMake