forked from polaris-MCRT/POLARIS
-
Notifications
You must be signed in to change notification settings - Fork 0
69 lines (66 loc) · 2.31 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: CI
on:
push:
branches: [ master-basic ]
pull_request:
branches: [ master-basic ]
defaults:
run:
# use interactive shell, i.e. it should source .bashrc
shell: bash -ieo pipefail {0}
jobs:
ubuntu-compile-script:
strategy:
matrix:
compiler: ["gcc", "clang++"]
generator: ["make", "ninja"]
fail-fast: false
name: "Ubuntu compile.sh :: ${{ matrix.compiler }} :: ${{ matrix.generator }}"
runs-on: ubuntu-latest
steps:
- run: sudo apt-get update -yy && sudo apt-get install -yy ninja-build
- uses: actions/checkout@v3
- run: ./compile.sh -f -c ${{ matrix.compiler }} -g ${{ matrix.generator }}
- run: ./src/build/tests -as
- run: ./ci/test.sh polaris projects
ubuntu-cmake:
strategy:
matrix:
include:
- compiler: gcc
defines: "CC=gcc CXX=g++"
build_type: "Release"
- compiler: clang
defines: "CC=clang CXX=clang++"
build_type: "Release"
- compiler: clang
defines: "CC=clang CXX=clang++"
build_type: "Debug"
exe_linker_flags: "-fsanitize=address"
cxx_flags: "-fsanitize=address"
fail-fast: false
name: "Ubuntu :: ${{ matrix.compiler }} :: ${{ matrix.build_type }} :: ${{ matrix.cxx_flags }} :: system ccfits cfitsio"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: sudo apt-get update -yy && sudo apt-get install -yy ninja-build libccfits-dev libcfitsio-dev
- run: |
mkdir build
cd build
${{ matrix.defines }} cmake ../src -GNinja -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DCMAKE_EXE_LINKER_FLAGS=${{ matrix.exe_linker_flags }} -DCMAKE_CXX_FLAGS=${{ matrix.cxx_flags }}
ninja
ninja test
- run: ./ci/test.sh ./build/polaris projects
macos-cmake-llvm:
name: "MacOS :: llvm :: system ccfits cfitsio"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- run: brew install llvm libomp ninja ccfits cfitsio
- run: |
mkdir build
cd build
CC="$(brew --prefix llvm)/bin/clang" CXX="$(brew --prefix llvm)/bin/clang++" cmake ../src -DCMAKE_BUILD_TYPE=Release -GNinja
ninja
ninja test
- run: ./ci/test.sh ./build/polaris projects