Skip to content

Commit

Permalink
Add Github Actions for the Python wheels
Browse files Browse the repository at this point in the history
  • Loading branch information
Stealthii committed Nov 17, 2023
1 parent cd8c800 commit 592f0d3
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build Wheels

on: [push, pull_request]

jobs:
build-wheels:
name: Build wheels on ${{ matrix.os }} for Python ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: [3.8, 3.11]

steps:
- uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine build
- name: Install cibuildwheel
run: python -m pip install cibuildwheel

- name: Build the wheels
run: python -m cibuildwheel --output-dir wheelhouse
env:
CIBW_BUILD: cp${{ matrix.python-version }}-*
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
CIBW_MANYLINUX_I686_IMAGE: manylinux2014
CIBW_MANYLINUX_PYPY_X86_64_IMAGE: manylinux2014
CIBW_BEFORE_BUILD: pip install pybind11
working-directory: ./python

- uses: actions/upload-artifact@v2
with:
name: wheels
path: ./python/wheelhouse/*.whl

0 comments on commit 592f0d3

Please sign in to comment.