diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 43fe6f1..cf6f009 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -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 }} @@ -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: diff --git a/src/streaming/thread.pool.cpp b/src/streaming/thread.pool.cpp index 2550dd8..aede31d 100644 --- a/src/streaming/thread.pool.cpp +++ b/src/streaming/thread.pool.cpp @@ -1,5 +1,7 @@ #include "thread.pool.hh" +#include + zarr::ThreadPool::ThreadPool(unsigned int n_threads, ErrorCallback&& err) : error_handler_{ std::move(err) } {