diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c23c64d..1dee63c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -39,6 +39,7 @@ jobs: python-version: '3.12' - name: Build wheels + uses: pypa/cibuildwheel@v2.19.1 env: CIBW_BUILD: "cp3*" CIBW_SKIP: "*-win32 *-manylinux_i686 *-musllinux_*" @@ -47,13 +48,13 @@ jobs: CIBW_TEST_COMMAND: "pytest {project}/tests" # Skip testing on arm64 Python 3.8 because it uses the x86_64 executable, not the arm executable CIBW_TEST_SKIP: "cp38-macosx_*:arm64" + # Clean the build directory between builds + CIBW_BEFORE_BUILD: >- + rm -rf {package}/build CIBW_ENVIRONMENT_LINUX: CMAKE_GENERATOR="Unix Makefiles" CIBW_ENVIRONMENT_MACOS: CMAKE_GENERATOR="Unix Makefiles" CMAKE_OSX_ARCHITECTURES=${{ matrix.osx_arch }} CIBW_ENVIRONMENT_WINDOWS: CMAKE_GENERATOR="Visual Studio 17 2022" CMAKE_GENERATOR_PLATFORM=x64 CIBW_BUILD_VERBOSITY: 1 - run: | - python -m pip install cibuildwheel build - python -m cibuildwheel --output-dir wheelhouse - name: Build source if: startsWith(matrix.os, 'ubuntu') @@ -74,6 +75,7 @@ jobs: with: name: wheels-${{ matrix.os }} path: ./wheelhouse + if-no-files-found: error merge_artifacts: name: Merge wheel artifacts from build_wheels OS matrix jobs