-
Notifications
You must be signed in to change notification settings - Fork 1
57 lines (49 loc) · 1.46 KB
/
build.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
name: build
on:
push:
branches: [ unstable ]
pull_request:
branches: [ unstable ]
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- {os: ubuntu-22.04, llvm: 15, doc: ON}
- {os: ubuntu-22.04, llvm: 16, doc: OFF}
- {os: ubuntu-22.04, llvm: 17, doc: OFF}
- {os: ubuntu-22.04, llvm: 18, doc: OFF}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install ubuntu dependencies
if: matrix.os == 'ubuntu-22.04'
run: >
sudo apt-get update &&
sudo apt-get install lsb-release wget software-properties-common &&
wget -O /tmp/llvm.sh https://apt.llvm.org/llvm.sh &&
chmod +x /tmp/llvm.sh && sudo /tmp/llvm.sh ${{ matrix.llvm }} &&
sudo apt-get install
ccache
clang-${{ matrix.llvm }}
clang-tools-${{ matrix.llvm }}
libclang-${{ matrix.llvm }}-dev
libhdf5-dev
python3
python3-dev
python3-numpy
python3-scipy
- name: Build c2py
env:
CC: clang-${{ matrix.llvm }}
CXX: clang++-${{ matrix.llvm }}
LIBRARY_PATH: /usr/local/opt/llvm/lib
CMAKE_PREFIX_PATH: /usr/lib/llvm-${{ matrix.llvm }}/lib/cmake/clang
run: |
mkdir build && cmake -B build -DCMAKE_INSTALL_PREFIX=/opt/c2py
cmake --build build -j2
- name: Test clair
run: |
cd build
ctest -j2 --output-on-failure