Skip to content

Commit 6570592

Browse files
Add C++-Modules Based Linux CI workflow
- 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
1 parent ea85b81 commit 6570592

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

.github/workflows/linux.yml

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,10 @@ jobs:
3333
std: 23
3434
install: sudo apt install g++-13
3535
shared: -DBUILD_SHARED_LIBS=ON
36+
- cxx: g++-14
37+
build_type: Release
38+
std: 23
39+
install: sudo apt install g++-14
3640
- cxx: clang++-11
3741
build_type: Debug
3842
std: 17
@@ -53,6 +57,11 @@ jobs:
5357
std: 20
5458
cxxflags: -stdlib=libc++
5559
install: sudo apt install libc++-14-dev libc++abi-14-dev
60+
- cxx: clang++-20
61+
build_type: Debug
62+
std: 20
63+
cxxflags: -stdlib=libc++
64+
install: sudo apt install clang-20 libc++-20-dev libc++abi-20-dev
5665

5766
steps:
5867
- uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
@@ -129,7 +138,14 @@ jobs:
129138
- name: Add repositories for newer GCC
130139
run: |
131140
sudo apt-add-repository ppa:ubuntu-toolchain-r/test
132-
if: ${{ matrix.cxx == 'g++-13' }}
141+
if: ${{ matrix.cxx == 'g++-13' || matrix.cxx == 'g++-14' }}
142+
143+
- name: Install LLVM-20
144+
run: |
145+
wget https://apt.llvm.org/llvm.sh
146+
chmod +x llvm.sh
147+
sudo ./llvm.sh 20
148+
if: ${{ matrix.cxx == 'clang++-20' }}
133149

134150
- name: Add Ubuntu mirrors
135151
run: |
@@ -162,6 +178,23 @@ jobs:
162178
-DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \
163179
-DFMT_DOC=OFF -DFMT_PEDANTIC=ON -DFMT_WERROR=ON \
164180
${{matrix.fuzz}} ${{matrix.shared}} $GITHUB_WORKSPACE
181+
if: ${{ matrix.cxx != 'clang++-20' && matrix.cxx != 'g++-14' }}
182+
183+
- name: Configure-Modules
184+
working-directory: ${{runner.workspace}}/build
185+
env:
186+
CXX: ${{matrix.cxx}}
187+
CXXFLAGS: ${{matrix.cxxflags}}
188+
run: |
189+
cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
190+
-DCMAKE_CXX_STANDARD=${{matrix.std}} \
191+
-DCMAKE_CXX_EXTENSIONS=OFF \
192+
-G Ninja \
193+
-DCMAKE_CXX_VISIBILITY_PRESET=hidden \
194+
-DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \
195+
-DFMT_DOC=OFF -DFMT_PEDANTIC=ON \
196+
${{matrix.fuzz}} ${{matrix.shared}} $GITHUB_WORKSPACE
197+
if: ${{ matrix.cxx == 'clang++-20' || matrix.cxx == 'g++-14' }}
165198

166199
- name: Build
167200
working-directory: ${{runner.workspace}}/build

0 commit comments

Comments
 (0)