-
Notifications
You must be signed in to change notification settings - Fork 15
80 lines (63 loc) · 2.54 KB
/
wheels.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
name: Wheels
on:
workflow_dispatch:
release:
types:
- published
jobs:
build_wheels:
name: Wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-13, windows-latest] # macos-12 because we need an intel runner, see https://github.com/actions/runner-images/issues/9741
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: pypa/cibuildwheel@v2.21.1
with:
package-dir: SDK_wrapper
env:
CIBW_BUILD: cp*-manylinux_x86_64 cp*-macosx_x86_64 cp*-win_amd64
CIBW_BEFORE_BUILD_WINDOWS: "pip install delvewheel"
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: "delvewheel repair -w {dest_dir} --add-path .\\SDK_wrapper\\TittaMex\\64\\Windows {wheel}"
CIBW_MANYLINUX_X86_64_IMAGE: quay.io/pypa/manylinux_2_28_x86_64
CIBW_BEFORE_ALL_LINUX: dnf install -y avahi-libs && cp ./SDK_wrapper/TittaMex/64/Linux/libtobii_research.so /usr/lib && ldconfig -n -v /usr/lib
CIBW_BEFORE_BUILD_MACOS: uname -a
MACOSX_DEPLOYMENT_TARGET: 10.15
- uses: pypa/cibuildwheel@v2.21.1
with:
package-dir: LSL_streamer
env:
CIBW_BUILD: cp*-manylinux_x86_64 cp*-macosx_x86_64 cp*-win_amd64
CIBW_BEFORE_BUILD_WINDOWS: "pip install delvewheel"
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: "delvewheel repair -w {dest_dir} --add-path .\\SDK_wrapper\\TittaMex\\64\\Windows;.\\LSL_streamer\\TittaLSLMex\\+TittaLSL\\+detail {wheel}"
CIBW_MANYLINUX_X86_64_IMAGE: quay.io/pypa/manylinux_2_28_x86_64
CIBW_BEFORE_ALL_LINUX: dnf install -y avahi-libs && cp ./LSL_streamer/TittaLSLMex/+TittaLSL/+detail/libtobii_research.so /usr/lib && cp ./LSL_streamer/TittaLSLMex/+TittaLSL/+detail/liblsl.so /usr/lib && ldconfig -n -v /usr/lib
CIBW_BEFORE_BUILD_MACOS: uname -a
MACOSX_DEPLOYMENT_TARGET: 10.15
- name: Verify clean directory
run: git diff --exit-code
shell: bash
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: dist-${{ matrix.os }}
path: wheelhouse/*.whl
upload_all:
name: Upload if release
needs: [build_wheels]
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- uses: actions/download-artifact@v4
with:
pattern: dist-*
merge-multiple: true
path: dist
- uses: pypa/gh-action-pypi-publish@v1.10.2
with:
user: __token__
password: ${{ secrets.pypi_password }}