diff --git a/.github/workflows/build-wheel.yml b/.github/workflows/build-wheel.yml index e569c73f4..5a7544011 100644 --- a/.github/workflows/build-wheel.yml +++ b/.github/workflows/build-wheel.yml @@ -44,7 +44,7 @@ jobs: build_wheel_unix: strategy: matrix: - os: [ubuntu-latest] + os: [macos-latest, ubuntu-latest] name: Build [${{ matrix.os }}] using cibuildwheel runs-on: ${{ matrix.os }} steps: @@ -62,7 +62,9 @@ jobs: name: cx-freeze-wheelhouse path: wheelhouse publish: - needs: windows + needs: + - build_wheel_windows + - build_wheel_unix runs-on: ubuntu-latest name: Publish package to PyPI steps: diff --git a/pyproject.toml b/pyproject.toml index 2825a0f21..3d7701759 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,3 +58,13 @@ build-verbosity = "1" before-build = "(cd /opt/_internal && tar -xvf static-libs-for-embedding-only.tar.xz)" build = "cp3*-manylinux_x86_64" repair-wheel-command = "auditwheel repair -L /bases/lib -w {dest_dir} {wheel}" + +[tool.cibuildwheel.macos] +build = "cp3*-macosx_*" +archs = "x86_64 universal2 arm64" +skip = "cp38-macosx_universal2 cp38-macosx_arm64" +dependency-versions = "latest" +repair-wheel-command = """ +delocate-listdeps {wheel} && +delocate-wheel --require-archs {delocate_archs} -L bases/lib -w {dest_dir} {wheel} +"""