-
Notifications
You must be signed in to change notification settings - Fork 39
116 lines (102 loc) · 3.2 KB
/
macos-linux-windows-conda.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
116
name: CI - MacOS/Linux/Windows via Pixi
on:
push:
paths-ignore:
- 'doc/**'
- '.gitlab-ci.yml'
- '.gitignore'
- '*.md'
- 'LICENSE'
- 'colcon.pkg'
- '.pre-commit-config.yaml'
pull_request:
paths-ignore:
- 'doc/**'
- '.gitlab-ci.yml'
- '.gitignore'
- '*.md'
- 'LICENSE'
- 'colcon.pkg'
- '.pre-commit-config.yaml'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
eigenpy-pixi:
name: ${{ matrix.os }} - Env ${{ matrix.environment }} ${{ matrix.build_type }} ${{ matrix.cxx_options }}
runs-on: ${{ matrix.os }}
env:
CCACHE_BASEDIR: "${GITHUB_WORKSPACE}"
CCACHE_DIR: "${GITHUB_WORKSPACE}/.ccache"
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 6
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, macos-14]
environment: [py38-ci, py312-ci, accelerate-ci]
build_type: [Release, Debug]
cxx_options: ['', '-mavx2']
exclude:
- os: ubuntu-latest
environment: accelerate-ci
- os: macos-latest
environment: accelerate-ci
- os: macos-latest
cxx_options: '-mavx2'
- os: macos-14
cxx_options: '-mavx2'
- os: macos-14
environment: py312-ci
include:
- os: windows-latest
environment: py312-ci
compiler: cl
- os: windows-latest
environment: py312-ci
compiler: clang-cl
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/cache@v4
with:
path: .ccache
key: ccache-macos-linux-windows-pixi-${{ matrix.os }}-${{ matrix.build_type }}-${{ matrix.cxx_options }}-${{ matrix.environment }}-${{ github.sha }}
restore-keys: ccache-macos-linux-windows-pixi-${{ matrix.os }}-${{ matrix.build_type }}-${{ matrix.cxx_options }}-${{ matrix.environment }}-
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.18.0
cache: true
environments: ${{ matrix.environment }}
- name: Build EigenPy [MacOS/Linux]
shell: pixi run bash -el {0}
if: contains(matrix.os, 'ubuntu') || contains(matrix.os, 'macos')
env:
CMAKE_BUILD_PARALLEL_LEVEL: 4
run: |
# We can't setup these variables in env because
# conda and pixi activation script can overwrite them
export CMAKE_BUILD_TYPE=${{ matrix.build_type }}
export CXXFLAGS=${{ matrix.cxx_options }}
pixi run -e ${{ matrix.environment }} test
- name: Build EigenPy [Windows]
shell: pixi run bash -el {0}
if: contains(matrix.os, 'windows')
env:
CC: ${{ matrix.compiler }}
CXX: ${{ matrix.compiler }}
CMAKE_BUILD_PARALLEL_LEVEL: 4
run: |
pixi run -e ${{ matrix.environment }} test
check:
if: always()
name: check-macos-linux-windows-pixi
needs:
- eigenpy-pixi
runs-on: Ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}