CI-unixish.yml: use `ccache` for some macos builds / cleanups (#4439)

This commit is contained in:
Oliver Stöneberg 2022-09-05 21:36:53 +02:00 committed by GitHub
parent 436b8bd3f1
commit 3d10e67b3d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 9 deletions

View File

@ -63,7 +63,6 @@ jobs:
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
if: contains(matrix.os, 'ubuntu')
with:
key: ${{ github.workflow }}-${{ github.job }}-${{ matrix.os }}
@ -88,7 +87,7 @@ jobs:
- name: CMake build on macos (with GUI)
if: contains(matrix.os, 'macos')
run: |
cmake -S . -B cmake.output -G "Unix Makefiles" -DHAVE_RULES=On -DBUILD_TESTS=On -DBUILD_GUI=On -DWITH_QCHART=On -DQt5_DIR=$(brew --prefix qt@5)/lib/cmake/Qt5
cmake -S . -B cmake.output -G "Unix Makefiles" -DHAVE_RULES=On -DBUILD_TESTS=On -DBUILD_GUI=On -DWITH_QCHART=On -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DQt5_DIR=$(brew --prefix qt@5)/lib/cmake/Qt5
cmake --build cmake.output -- -j$(nproc)
- name: Run CMake test
@ -114,7 +113,6 @@ jobs:
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
if: contains(matrix.os, 'ubuntu')
with:
key: ${{ github.workflow }}-${{ github.job }}-${{ matrix.os }}
@ -147,7 +145,6 @@ jobs:
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
if: contains(matrix.os, 'ubuntu')
with:
key: ${{ github.workflow }}-${{ github.job }}-${{ matrix.os }}
@ -178,13 +175,12 @@ jobs:
steps:
- uses: actions/checkout@v2
# coreutils contains "g++" and "nproc"
# coreutils contains "g++" (default is "c++") and "nproc"
- name: Install missing software on macos
if: contains(matrix.os, 'macos')
run: |
brew install coreutils
# TODO: can we use c++ instead?
- name: Check syntax with NONNEG
run: |
ls lib/*.cpp | xargs -n 1 -P $(nproc) g++ -fsyntax-only -std=c++0x -Ilib -Iexternals -Iexternals/picojson -Iexternals/simplecpp -Iexternals/tinyxml2 -DNONNEG
@ -277,7 +273,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-20.04, ubuntu-22.04, macos-11, macos-12]
os: [ubuntu-20.04, ubuntu-22.04] # only needs to build on ubuntu
fail-fast: false # Prefer quick result
runs-on: ${{ matrix.os }}
@ -286,7 +282,6 @@ jobs:
- uses: actions/checkout@v2
- name: Build Fuzzer
if: contains(matrix.os, 'ubuntu')
run: |
pushd oss-fuzz
make -j$(nproc) CXX=clang++ CXXFLAGS="-fsanitize=address" fuzz-client translate
@ -305,7 +300,6 @@ jobs:
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
if: contains(matrix.os, 'ubuntu')
with:
key: ${{ github.workflow }}-${{ github.job }}-${{ matrix.os }}