-
Notifications
You must be signed in to change notification settings - Fork 31
115 lines (82 loc) · 2.72 KB
/
test_install.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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
name: Installation
on: [push, pull_request, merge_group, workflow_dispatch]
jobs:
archive:
name: Archive Install
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: [3.9]
steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v3
- run: git fetch --prune --unshallow
- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies
- name: apt
run: |
sudo apt-get update \
&& sudo apt-get install -y \
cmake
- name: Build suitesparse
run: scripts/buildSuiteSparse.sh
- name: Build sundials
run: scripts/buildSundials.sh
- name: Build AMICI
run: scripts/buildAmici.sh
- name: Install python archive
run: scripts/installAmiciArchive.sh
sdist_ubuntu:
name: sdist Install Ubuntu
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: [3.9]
steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v3
- run: git fetch --prune --unshallow
- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV
- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies
- name: Create AMICI sdist
run: scripts/buildSdist.sh
- name: Install python sdist
run: pip3 install -v --user $(ls -t python/sdist/dist/amici-*.tar.gz | head -1)
- name: Test import
run: python -m amici
sdist_macos:
name: sdist Install macos
runs-on: macos-latest
strategy:
matrix:
python-version: [3.9]
steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v3
- run: git fetch --prune --unshallow
- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV
# install amici dependencies
- name: homebrew
run: |
brew install hdf5 swig gcc cppcheck libomp boost \
&& brew ls -v boost \
&& brew ls -v libomp \
&& echo LDFLAGS="-L/usr/local/lib/ -L/usr/local/Cellar/boost/1.81.0_1/lib/" >> $GITHUB_ENV \
&& echo CPPFLAGS="-I /usr/local/Cellar/boost/1.81.0_1/include/" >> $GITHUB_ENV
- name: Create AMICI sdist
run: scripts/buildSdist.sh
- name: Install python sdist
run: pip3 install -v --user $(ls -t python/sdist/dist/amici-*.tar.gz | head -1)
- name: Test import
run: python -m amici