diff --git a/.github/workflows/cibuildwheel.yml b/.github/workflows/cibuildwheel.yml index 7ae41da..ded5dc6 100644 --- a/.github/workflows/cibuildwheel.yml +++ b/.github/workflows/cibuildwheel.yml @@ -7,9 +7,12 @@ jobs: name: Build wheels on ${{ matrix.os }} runs-on: ${{ matrix.os }} strategy: + fail-fast: false matrix: os: [windows-latest, macOS-latest, ubuntu-latest] - + env: + THERMOPACK_DIR: thermopack-${{ matrix.os }} + THERMOPACK_URL: https://github.com/vegardjervell/thermopack/releases/download/Latest-beta steps: - uses: actions/checkout@v4 - name: checkout submodules @@ -18,12 +21,28 @@ jobs: # Used to host cibuildwheel - uses: actions/setup-python@v4 - - name: Install cibuildwheel and other dependencies - run: python -m pip install cibuildwheel==2.17.0 build wheel setuptools + - name: Fetch Thermopack + if: runner.os != 'windows-latest' + run: | + curl -L -o thermopack.zip ${{ env.THERMOPACK_URL }}/thermopack-${{ matrix.os }}.zip + unzip thermopack.zip + export THERMOPACK_DIR=${PWD}/thermopack-${{ matrix.os }}/ + curl -L -o thermopack_whl.zip ${{ env.THERMOPACK_URL }}/wheel-v2-${{ matrix.os }}.zip + unzip thermopack_whl.zip + pip install wheel-v2-${{ matrix.os }}/* - - name: Build sdist - run: pipx run build --sdist --outdir wheelhouse - if: runner.os == 'Windows' + - name: Fetch Thermopack (Windows) + if: runner.os == 'windows-latest' + shell: pwsh + run: | + Invoke-WebRequest -Uri "${{ env.THERMOPACK_URL }}/thermopack-${{ matrix.os }}.zip" -OutFile "thermopack.zip" + Expand-Archive -Path "thermopack.zip" -DestinationPath "${{ env.THERMOPACK_DIR }}" + $THERMOPACK_DIR = "$PWD\${{ env.THERMOPACK_DIR }}\thermopack-${{ matrix.os }}" + [System.Environment]::SetEnvironmentVariable("THERMOPACK_DIR", $THERMOPACK_DIR) + Invoke-WebRequest -Uri "${{ env.THERMOPACK_URL }}/wheel-v2-${{ matrix.os }}.zip" -OutFile "thermopack_whl.zip" + Expand-Archive -Path "thermopack_whl.zip" -DestinationPath "wheel-v2-${{ matrix.os }}" + cd wheel-v2-${{ matrix.os }} + pip install (Get-ChildItem wheel-v2-windows-latest\*.whl).FullName - name: Build wheels uses: pypa/cibuildwheel@v2.19.1 # run: python -m cibuildwheel --output-dir wheelhouse