Add C++-Modules Based Linux CI workflow (#4708)
- This adds a set of CI tests for linux that include compilers that support modules - This CI workflow uses ninja as the build system generator - Can be integrated with the other linux workflow after successful testing Co-authored-by: Mathew Benson <mathew@benson.co.ke>
This commit is contained in:
co-authored by
Mathew Benson
parent
602df7dab8
commit
cdb8dc76d9
@@ -33,6 +33,10 @@ jobs:
|
|||||||
std: 23
|
std: 23
|
||||||
install: sudo apt install g++-13
|
install: sudo apt install g++-13
|
||||||
shared: -DBUILD_SHARED_LIBS=ON
|
shared: -DBUILD_SHARED_LIBS=ON
|
||||||
|
- cxx: g++-14
|
||||||
|
build_type: Release
|
||||||
|
std: 23
|
||||||
|
install: sudo apt install g++-14
|
||||||
- cxx: clang++-11
|
- cxx: clang++-11
|
||||||
build_type: Debug
|
build_type: Debug
|
||||||
std: 17
|
std: 17
|
||||||
@@ -55,6 +59,11 @@ jobs:
|
|||||||
std: 20
|
std: 20
|
||||||
cxxflags: -stdlib=libc++
|
cxxflags: -stdlib=libc++
|
||||||
install: sudo apt install libc++-14-dev libc++abi-14-dev
|
install: sudo apt install libc++-14-dev libc++abi-14-dev
|
||||||
|
- cxx: clang++-20
|
||||||
|
build_type: Debug
|
||||||
|
std: 20
|
||||||
|
cxxflags: -stdlib=libc++
|
||||||
|
install: sudo apt install clang-20 libc++-20-dev libc++abi-20-dev
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
|
- uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
|
||||||
@@ -131,7 +140,14 @@ jobs:
|
|||||||
- name: Add repositories for newer GCC
|
- name: Add repositories for newer GCC
|
||||||
run: |
|
run: |
|
||||||
sudo apt-add-repository ppa:ubuntu-toolchain-r/test
|
sudo apt-add-repository ppa:ubuntu-toolchain-r/test
|
||||||
if: ${{ matrix.cxx == 'g++-13' }}
|
if: ${{ matrix.cxx == 'g++-13' || matrix.cxx == 'g++-14' }}
|
||||||
|
|
||||||
|
- name: Install LLVM-20
|
||||||
|
run: |
|
||||||
|
wget https://apt.llvm.org/llvm.sh
|
||||||
|
chmod +x llvm.sh
|
||||||
|
sudo ./llvm.sh 20
|
||||||
|
if: ${{ matrix.cxx == 'clang++-20' }}
|
||||||
|
|
||||||
- name: Add Ubuntu mirrors
|
- name: Add Ubuntu mirrors
|
||||||
run: |
|
run: |
|
||||||
@@ -164,6 +180,23 @@ jobs:
|
|||||||
-DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \
|
-DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \
|
||||||
-DFMT_DOC=OFF -DFMT_PEDANTIC=ON -DFMT_WERROR=ON \
|
-DFMT_DOC=OFF -DFMT_PEDANTIC=ON -DFMT_WERROR=ON \
|
||||||
${{matrix.fuzz}} ${{matrix.shared}} $GITHUB_WORKSPACE
|
${{matrix.fuzz}} ${{matrix.shared}} $GITHUB_WORKSPACE
|
||||||
|
if: ${{ matrix.cxx != 'clang++-20' && matrix.cxx != 'g++-14' }}
|
||||||
|
|
||||||
|
- name: Configure-Modules
|
||||||
|
working-directory: ${{runner.workspace}}/build
|
||||||
|
env:
|
||||||
|
CXX: ${{matrix.cxx}}
|
||||||
|
CXXFLAGS: ${{matrix.cxxflags}}
|
||||||
|
run: |
|
||||||
|
cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
|
||||||
|
-DCMAKE_CXX_STANDARD=${{matrix.std}} \
|
||||||
|
-DCMAKE_CXX_EXTENSIONS=OFF \
|
||||||
|
-G Ninja \
|
||||||
|
-DCMAKE_CXX_VISIBILITY_PRESET=hidden \
|
||||||
|
-DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \
|
||||||
|
-DFMT_DOC=OFF -DFMT_PEDANTIC=ON \
|
||||||
|
${{matrix.fuzz}} ${{matrix.shared}} $GITHUB_WORKSPACE
|
||||||
|
if: ${{ matrix.cxx == 'clang++-20' || matrix.cxx == 'g++-14' }}
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
|
|||||||
Reference in New Issue
Block a user