-
Notifications
You must be signed in to change notification settings - Fork 61
82 lines (80 loc) · 2.54 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: LAGraph CI with Builtin GraphBLAS
on:
workflow_dispatch:
push:
branches-ignore:
- '**/*dev2'
pull_request:
jobs:
linux:
runs-on: ubuntu-22.04
strategy:
matrix:
config:
- {grb_version: 9.3.1}
steps:
- name: Checkout
uses: actions/[email protected]
- name: Install tools for build
run: |
sudo apt install -y lcov
- name: Build GraphBLAS
run: |
git clone https://github.com/DrTimothyAldenDavis/GraphBLAS.git
cd GraphBLAS
git checkout tags/v${{ matrix.config.grb_version }}
make compact
sudo make install
cd ..
- name: Build project
run: |
export GRAPHBLAS_INCLUDE_DIR=`pwd`/GraphBLAS/include/suitesparse
export GRAPHBLAS_LIBRARY=`pwd`/GraphBLAS/lib/libgraphblas.so
cd build
cmake .. -DCOVERAGE=1 -DGRAPHBLAS_INCLUDE_DIR=${GRAPHBLAS_INCLUDE_DIR} -DGRAPHBLAS_LIBRARY=${GRAPHBLAS_LIBRARY}
JOBS=2 make
make test_coverage
- name: Deploy
uses: JamesIves/[email protected]
if: matrix.config.grb_version == '9.1.0' && github.event_name == 'push' && github.ref == 'refs/heads/stable'
with:
branch: gh-pages
folder: build/test_coverage/
single-commit: true
- name: Save output
uses: actions/[email protected]
with:
name: test_coverage
path: build/test_coverage/
macos:
runs-on: macos-12
strategy:
matrix:
config:
- {grb_version: 9.3.1}
steps:
- name: Checkout
uses: actions/[email protected]
- name: Install dependencies
run: |
brew tap-new libomp/cask
brew extract --version=14.0.6 libomp libomp/cask
brew install [email protected]
- name: Build GraphBLAS
run: |
git clone https://github.com/DrTimothyAldenDavis/GraphBLAS.git
cd GraphBLAS
git checkout tags/v${{ matrix.config.grb_version }}
make compact
sudo make install
cd ..
- name: Build project
run: |
export GRAPHBLAS_INCLUDE_DIR=`pwd`/GraphBLAS/include/suitesparse
export GRAPHBLAS_LIBRARY=`pwd`/GraphBLAS/lib/libgraphblas.dylib
# adding an extra line to the CMakeLists.txt file to locate the libomp instance installed by brew
echo 'include_directories("/usr/local/opt/libomp/include")' | cat - CMakeLists.txt
cd build
CC=gcc cmake .. -DGRAPHBLAS_INCLUDE_DIR=${GRAPHBLAS_INCLUDE_DIR} -DGRAPHBLAS_LIBRARY=${GRAPHBLAS_LIBRARY}
JOBS=2 make
make test