forked from elhuhdron/pylibczi
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #116 from AllenCellModeling/fix/cibuildwheel
update cibuildwheel to fix windows build
- Loading branch information
Showing
1 changed file
with
39 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -61,20 +61,19 @@ jobs: | |
needs: [python-test, lint] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- name: Build SDist | ||
run: pipx run build --sdist | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- name: Check metadata | ||
run: pipx run twine check dist/* | ||
- name: Build SDist | ||
run: pipx run build --sdist | ||
|
||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: dist/*.tar.gz | ||
- name: Check metadata | ||
run: pipx run twine check dist/* | ||
|
||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: dist/*.tar.gz | ||
|
||
build_wheels: | ||
name: Wheels on ${{ matrix.cibw-arch }} | ||
|
@@ -96,26 +95,26 @@ jobs: | |
cibw-arch: win_amd64 | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- uses: pypa/cibuildwheel@v2.12.1 | ||
env: | ||
CIBW_BUILD: "*-${{ matrix.cibw-arch }}" | ||
CIBW_BEFORE_ALL_LINUX: yum install -y zlib-devel libpng-devel | ||
CIBW_TEST_EXTRAS: test | ||
CIBW_TEST_COMMAND: pytest {project}/aicspylibczi/tests | ||
CIBW_ARCHS_MACOS: x86_64 universal2 arm64 | ||
CMAKE_OSX_ARCHITECTURES: ${{ matrix.cibw-arch == 'macosx_x86_64' && 'x86_64' || matrix.cibw-arch == 'macosx_arm64' && 'arm64' || matrix.cibw-arch == 'macosx_universal2' && 'arm64;x86_64' || '' }} | ||
- name: Verify clean directory | ||
run: git diff --exit-code | ||
shell: bash | ||
|
||
- name: Upload wheels | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
path: wheelhouse/*.whl | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- uses: pypa/cibuildwheel@v2.17.0 | ||
env: | ||
CIBW_BUILD: "*-${{ matrix.cibw-arch }}" | ||
CIBW_BEFORE_ALL_LINUX: yum install -y zlib-devel libpng-devel | ||
CIBW_TEST_EXTRAS: test | ||
CIBW_TEST_COMMAND: pytest {project}/aicspylibczi/tests | ||
CIBW_ARCHS_MACOS: x86_64 universal2 arm64 | ||
CMAKE_OSX_ARCHITECTURES: ${{ matrix.cibw-arch == 'macosx_x86_64' && 'x86_64' || matrix.cibw-arch == 'macosx_arm64' && 'arm64' || matrix.cibw-arch == 'macosx_universal2' && 'arm64;x86_64' || '' }} | ||
- name: Verify clean directory | ||
run: git diff --exit-code | ||
shell: bash | ||
|
||
- name: Upload wheels | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
path: wheelhouse/*.whl | ||
|
||
upload_all: | ||
name: Upload if release | ||
|
@@ -124,14 +123,14 @@ jobs: | |
if: "contains(github.event.head_commit.message, 'Bump version')" | ||
|
||
steps: | ||
- uses: actions/setup-python@v5 | ||
- uses: actions/setup-python@v5 | ||
|
||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: artifact | ||
path: dist | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: artifact | ||
path: dist | ||
|
||
- uses: pypa/[email protected] | ||
with: | ||
user: aicspypi | ||
password: ${{ secrets.PYPI_TOKEN }} | ||
- uses: pypa/[email protected] | ||
with: | ||
user: aicspypi | ||
password: ${{ secrets.PYPI_TOKEN }} |