File tree Expand file tree Collapse file tree 3 files changed +139
-0
lines changed Expand file tree Collapse file tree 3 files changed +139
-0
lines changed Original file line number Diff line number Diff line change 1+ name : MacOS
2+
3+ on :
4+ push :
5+ branches : ["main", "devel"]
6+ pull_request :
7+ branches : ["main", "devel"]
8+
9+ env :
10+ # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
11+ BUILD_TYPE : Debug
12+
13+ jobs :
14+ macos :
15+ # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
16+ # You can convert this to a matrix build if you need cross-platform coverage.
17+ # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
18+ runs-on : macos-latest
19+
20+ steps :
21+ - uses : actions/checkout@v3
22+
23+ - name : Install Brew Dependencies
24+ run : brew install llvm@19 git googletest
25+
26+ - name : Tool Version Dump
27+ run : |
28+ clang++ --version
29+ cmake --version
30+ ninja --version
31+
32+ - name : Configure CMake
33+ run : cmake -B ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}} -G"Ninja" -DTRAITS_LIBRARY_ENABLE_TESTS=on -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_CXX_EXTENSIONS=off -DCMAKE_CXX_COMPILER=/opt/homebrew/opt/llvm@19/bin/clang++ -DCMAKE_C_COMPILER=/opt/homebrew/opt/llvm@19/bin/clang -DCMAKE_CXX_STANDARD=20
34+ env :
35+ LDFLAGS : " -L/opt/homebrew/opt/llvm@19/lib/c++ -L/opt/homebrew/opt/llvm@19/lib/unwind -lunwind"
36+ CPPFLAGS : " -I/opt/homebrew/opt/llvm@19/include -I/opt/homebrew/include"
37+
38+ - name : Build
39+ run : cmake --build ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}} --config ${{env.BUILD_TYPE}}
40+
41+ - name : Test
42+ working-directory : ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}}
43+ run : ./tests/traits-tests
Original file line number Diff line number Diff line change 1+ name : Ubuntu
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ - devel
8+ - ' feat/*'
9+ - ' fix/*'
10+ pull_request :
11+ branches : ["main", "devel"]
12+
13+ env :
14+ # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
15+ BUILD_TYPE : Release
16+
17+ jobs :
18+ compiler_matrix :
19+ runs-on : ubuntu-24.04
20+ strategy :
21+ matrix :
22+ cxx_standard : [20, 23]
23+ clang_version : ["17", "18", "19", "20"]
24+
25+ steps :
26+ - uses : actions/checkout@v3
27+ - uses : awalsh128/cache-apt-pkgs-action@latest
28+ with :
29+ packages : ninja-build libgtest-dev libgmock-dev
30+
31+ - name : Install clang
32+ run : |
33+ wget https://apt.llvm.org/llvm.sh
34+ chmod +x llvm.sh
35+ sudo ./llvm.sh ${{ matrix.clang_version }}
36+ sudo apt-get install -y clang-${{ matrix.clang_version }} lld-${{ matrix.clang_version }} libc++-${{ matrix.clang_version }}-dev libc++abi-${{ matrix.clang_version }}-dev
37+
38+ - name : Tool Version Dump
39+ run : |
40+ clang++ --version
41+ cmake --version
42+ ninja --version
43+
44+ - name : Symlink xlocale
45+ run : sudo ln -s /usr/include/locale.h /usr/include/xlocale.h
46+
47+ - name : Configure CMake
48+ run : cmake -B ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}} -G"Ninja" -DTRAITS_LIBRARY_ENABLE_TESTS=on -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_CXX_FLAGS="-stdlib=libc++" -DCMAKE_CXX_EXTENSIONS=on -DCMAKE_CXX_COMPILER=clang++-${{ matrix.clang_version }} -DCMAKE_C_COMPILER=clang-${{ matrix.clang_version }} -DCMAKE_LINKER=lld-${{ matrix.clang_version }} -DCMAKE_CXX_STANDARD=${{ matrix.cxx_standard }}
49+ env :
50+ Boost_ROOT : ${{ steps.install-boost.outputs.BOOST_ROOT }}
51+
52+ - name : Build
53+ run : cmake --build ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}} --config ${{env.BUILD_TYPE}}
54+
55+ - name : Test
56+ working-directory : ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}}
57+ run : ./tests/traits-tests
Original file line number Diff line number Diff line change 1+ name : Windows
2+
3+ on :
4+ push :
5+ branches : ["main", "devel"]
6+ pull_request :
7+ branches : ["main", "devel"]
8+
9+ env :
10+ # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
11+ BUILD_TYPE : Debug
12+
13+ jobs :
14+ windows-msys2 :
15+ runs-on : windows-latest
16+ defaults :
17+ run :
18+ shell : msys2 {0}
19+
20+ steps :
21+ - uses : actions/checkout@v3
22+ - uses : msys2/setup-msys2@v2
23+ with :
24+ msystem : clang64
25+ release : true
26+ install : mingw-w64-clang-x86_64-clang make unzip mingw-w64-clang-x86_64-cmake mingw-w64-clang-x86_64-ninja mingw-w64-clang-x86_64-gtest
27+
28+ - name : Workspace Path Fixup
29+ run : echo "WSPACE=$(cygpath '${{github.workspace}}')" >> $GITHUB_ENV
30+
31+ - name : Configure CMake
32+ run : cmake -B ${{env.WSPACE}}/build/clang_${{env.BUILD_TYPE}} -G"Ninja" -DTRAITS_LIBRARY_ENABLE_TESTS=on -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_CXX_EXTENSIONS=off -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_LINKER=lld -DCMAKE_CXX_STANDARD=20
33+
34+ - name : Build
35+ run : cmake --build ${{env.WSPACE}}/build/clang_${{env.BUILD_TYPE}} --config ${{env.BUILD_TYPE}}
36+
37+ - name : Test
38+ working-directory : ${{github.workspace}}/build/clang_${{env.BUILD_TYPE}}
39+ run : ./tests/traits-tests.exe
You can’t perform that action at this time.
0 commit comments