Skip to content

Wheels

Wheels #61

Workflow file for this run

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/[email protected]
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/[email protected]
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/[email protected]
with:
user: __token__
password: ${{ secrets.pypi_password }}