Skip to content

Commit

Permalink
Update actions/checkout in GitHub Actions to v4 (#63, thanks @striezel)
Browse files Browse the repository at this point in the history
* Update actions/checkout in GitHub Actions to v4

* Add workaround for incompatibilities between Clang and libstdc++

See <actions/runner-images#8659> for
more information. Currently, Clang and libstdc++ provided by the
GitHub Actions runner image are incompatible. The basic idea of
this workaround is to remove the incompatible g++ 13 and its C++
standard library and replace that with a compatible version of
libstdc++.
  • Loading branch information
striezel committed Jan 15, 2024
1 parent 45a54fa commit 3634b0a
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions .github/workflows/ci.yml
Expand Up @@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Install GCC ${{ matrix.version }}
run: sudo apt-get install -y gcc-${{ matrix.version }} g++-${{ matrix.version }}
Expand Down Expand Up @@ -52,7 +52,16 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

# Workaround for incompatible clang and libstc++ versions, see
# <https://github.com/actions/runner-images/issues/8659> for more info.
# The basic idea here is to remove g++ 13 and its C++ standard library
# and replace that with a compatible version of libstdc++.
- name: Workaround for GHA issue 8659
run: |
sudo apt-get purge -y g++-13 gcc-13 libstdc++-13-dev
sudo apt-get install -y --allow-downgrades libstdc++-12-dev libstdc++6=12.* libgcc-s1=12.*
- name: Install Clang ${{ matrix.version }}
run: sudo apt-get install -y clang-${{ matrix.version }}
Expand All @@ -61,7 +70,7 @@ jobs:
env:
CXX: clang-${{ matrix.version }}
run: cmake -S . -B build
-D CMAKE_CXX_COMPILER=clang++
-D CMAKE_CXX_COMPILER=clang++-${{ matrix.version }}
-D CMAKE_BUILD_TYPE:STRING=Release
-D ${{ env.PROJECT }}_OPT_SELECT_NONSTD=ON
-D ${{ env.PROJECT }}_OPT_BUILD_TESTS=ON
Expand All @@ -83,7 +92,7 @@ jobs:
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Configure tests
run: cmake -S . -B build
Expand Down

0 comments on commit 3634b0a

Please sign in to comment.