Skip to content

Commit

Permalink
Fixes #259: Finish Feature Request by Adding Support for musllinux Wh…
Browse files Browse the repository at this point in the history
…eels and Testing Script for Alpine Compatibility (#261)

* Update pyproject.toml to add cibuildwheel as a development dependency

* add make-musllinux-wheels

* update poetry.lock since there is changes to pyproject.toml

* add test script to check compatibility with alpine

* include expected output of the test script as comment at the bottom of the file

* run-precommit hooks

* merge make-musllinux-wheels into make-wheels , and set py version globally using variable CIBW_BUILD_VERSIONS

* update test_musllinux_wheel.sh based on changes in .github/workflows/build.yml

* Update build.yml

* add comments on the python version definition

* resolve musllinux build failure by using apk for musllinux images, this is caused by the absence of `yum` in Alpine-based musllinux images

* Update test_musllinux_wheel.sh

* version 6.5.6

---------

Co-authored-by: Jannik Kissinger <github@michelfe.it>
  • Loading branch information
Pxli9130 and jannikmi authored Dec 2, 2024
1 parent 1fe86cf commit 5b5fd27
Show file tree
Hide file tree
Showing 5 changed files with 298 additions and 127 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
- master
workflow_dispatch:

env:
# the supported Python versions for pre-built wheels
CIBW_BUILD_VERSIONS: "cp38-* cp39-* cp310-* cp311-* cp312-* cp313-*"

jobs:
pre-commit-hooks:
name: run pre-commit hooks
Expand All @@ -25,6 +29,8 @@ jobs:
# max-parallel: 8
fail-fast: false
matrix:
# all officially supported Python versions should be tested
# NOTE: need to match the versions in pyproject.toml > tox.ini
python-version:
- "3.8"
- "3.9"
Expand Down Expand Up @@ -59,7 +65,6 @@ jobs:
matrix:
os: ["ubuntu-latest"]
cibw_arch: ["native"]
cibw_build: ["cp38-* cp39-* cp310-* cp311-* cp312-* cp313-*"]
fail-fast: false

steps:
Expand All @@ -75,11 +80,13 @@ jobs:
output-dir: dist
env:
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
CIBW_BUILD: ${{ matrix.cibw_build }}
CIBW_SKIP: "*musllinux*"
CIBW_MUSLLINUX_X86_64_IMAGE: musllinux_1_1
CIBW_BUILD: ${{ env.CIBW_BUILD_VERSIONS }}
CIBW_SKIP: "cp36-* cp37-*"
CIBW_ARCHS: ${{ matrix.cibw_arch }}
CIBW_BUILD_FRONTEND: pip
CIBW_BEFORE_ALL_LINUX: yum install -y libffi-devel clang make
CIBW_BEFORE_ALL_LINUX_MANYLINUX2014: yum install -y libffi-devel clang make
CIBW_BEFORE_ALL_LINUX_MUSLLINUX_1_1: apk add --no-cache libffi-dev clang make
CIBW_BUILD_VERBOSITY: 1

- name: "Upload wheel as artifact"
Expand Down Expand Up @@ -118,7 +125,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
- name: Upgrade pip version
run: pip install -U pip
run: pip install --upgrade pip
- name: Install poetry
run: pip install poetry
- name: Fetch version
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@
Changelog
=========


6.5.6 (2024-11-25)
------------------

* add musllinux Wheels for Linux. Thanks to `Pxli9130 <https://github.com/Pxli9130 >`__


6.5.5 (2024-11-20)
------------------

Expand Down
Loading

0 comments on commit 5b5fd27

Please sign in to comment.