Skip to content

Commit 32be74c

Browse files
committed
Add initial CI: Compilation pass
1 parent ebe5ebc commit 32be74c

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/build-cppfront.yaml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Multi-platform Build of cppfront
2+
on: push
3+
jobs:
4+
build-windows:
5+
runs-on: windows-latest
6+
steps:
7+
- uses: actions/checkout@v3
8+
- uses: ilammy/msvc-dev-cmd@v1
9+
- name: Compiler name & version
10+
run: cl.exe
11+
- name: Build
12+
run: cl.exe source/cppfront.cpp -std:c++latest -MD -EHsc -experimental:module -W4
13+
build-unix-like:
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
runs-on: [ubuntu-latest]
18+
compiler: [g++-10, g++-11, g++-12, clang++-12, clang++-14]
19+
cxx-std: ['c++20', 'c++2b']
20+
exclude:
21+
# GCC 10 doesn't have support for c++23
22+
- compiler: g++-10
23+
cxx-std: 'c++2b'
24+
include:
25+
- runs-on: macos-latest
26+
compiler: clang++
27+
cxx-std: 'c++20'
28+
runs-on: ${{ matrix.runs-on }}
29+
env:
30+
CXX: ${{ matrix.compiler }}
31+
CXXFLAGS: -std=${{ matrix.cxx-std }} -Wall -Wextra -Wold-style-cast -pthread
32+
steps:
33+
- uses: actions/checkout@v3
34+
- name: Install compiler
35+
if: startsWith(matrix.runs-on, 'ubuntu')
36+
run: sudo apt-get install -y ${{ matrix.compiler }}
37+
- name: Compiler name & version
38+
run: $CXX --version
39+
- name: Build
40+
run: $CXX source/cppfront.cpp $CXXFLAGS -o cppfront

0 commit comments

Comments
 (0)