Skip to content

Commit

Permalink
Manylinux release (#19)
Browse files Browse the repository at this point in the history
* use  to make the linux wheel a manylinux wheel

* Don't do release job on push to "manylinux-release"

* wip

* wip

* auditwheel repair

* Update to 22.04 for manylinux job.

* try without installing so many deps

* update release job

* wip

* done
  • Loading branch information
aliddell authored Nov 26, 2024
1 parent ec8fd1b commit d6228a2
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 14 deletions.
41 changes: 27 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ jobs:
matrix:
platform:
- "windows-latest"
- "ubuntu-latest"
- "macos-latest"
- "ubuntu-22.04"
- "macos-latest" # TODO (aliddell): universal binary?

runs-on: ${{ matrix.platform }}

Expand Down Expand Up @@ -156,23 +156,36 @@ jobs:
./vcpkg integrate install
shell: bash

- name: Install cibuildwheel
run: python -m pip install cibuildwheel
- name: Install system dependencies
if: ${{ matrix.platform == 'ubuntu-22.04' }}
run: |
sudo apt-get install patchelf
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 90
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 90
- name: Install Python dependencies
run: python -m pip install -U pip "pybind11[global]" cmake build numpy pytest auditwheel

- name: Install
run: python -m pip install ".[testing]"

- name: Build wheels
env:
CIBW_BUILD: "cp310-*" # Build for Python 3.10
CIBW_ARCHS: auto64 # Build for 64-bit architectures
CIBW_BEFORE_BUILD: pip install -U pip "pybind11[global]" cmake build numpy pytest
CIBW_TEST_REQUIRES: pytest
CIBW_TEST_COMMAND: pytest {package}/tests -v
run: python -m cibuildwheel --output-dir wheelhouse
- name: Test
run: python -m pytest -v

- name: Build
run: python -m build -o dist

- name: Fix wheel for manylinux
if: ${{ matrix.platform == 'ubuntu-22.04' }}
run: |
auditwheel repair dist/*.whl -w dist --plat manylinux_2_35_x86_64
rm dist/*-linux_*.whl
- name: Upload wheels
- name: Upload wheel
uses: actions/upload-artifact@v4
with:
name: ${{matrix.platform}} wheel
path: ./wheelhouse/*.whl
path: ${{github.workspace}}/dist/*.whl

release:
needs:
Expand Down
2 changes: 2 additions & 0 deletions src/streaming/thread.pool.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "thread.pool.hh"

#include <algorithm>

zarr::ThreadPool::ThreadPool(unsigned int n_threads, ErrorCallback&& err)
: error_handler_{ std::move(err) }
{
Expand Down

0 comments on commit d6228a2

Please sign in to comment.