diff --git a/.github/workflows/capi.yaml b/.github/workflows/capi.yaml index 65f35070c..a487b27e7 100644 --- a/.github/workflows/capi.yaml +++ b/.github/workflows/capi.yaml @@ -5,6 +5,7 @@ on: branches-ignore: - pycli - bump-pyo3-version + - windows-cli-wheels jobs: capi: diff --git a/.github/workflows/cli-wheels-windows.yml b/.github/workflows/cli-wheels-windows.yml index 52655c73f..e0d76e755 100644 --- a/.github/workflows/cli-wheels-windows.yml +++ b/.github/workflows/cli-wheels-windows.yml @@ -3,14 +3,12 @@ name: Generate CLI wheels for Windows # this workflow doesn't do (yet) what it promises; we keep this file to not lose the progress on: + push: workflow_dispatch: jobs: cli-wheels-windows: runs-on: windows-latest - strategy: - matrix: - target: [x64] defaults: run: shell: msys2 {0} @@ -26,12 +24,12 @@ jobs: gcc make autoconf - python3 curl tar - mingw-w64-ucrt-x86_64-pkg-config - mingw-w64-rust - mingw-w64-python-maturin + patch + mingw-w64-ucrt-x86_64-pkgconf + mingw-w64-ucrt-x86_64-rust + mingw-w64-ucrt-x86_64-python-maturin - uses: actions/setup-python@v5 with: # WARNING: be careful with the ordering - the last version is the @@ -50,25 +48,47 @@ jobs: 3.10 - name: Install LHAPDF run: | - curl "https://lhapdf.hepforge.org/downloads/?f=LHAPDF-6.5.4.tar.gz" | tar xzf - - cd LHAPDF-6.5.4 + export LHAPDF_V=6.5.4 + wget "https://lhapdf.hepforge.org/downloads/?f=LHAPDF-${LHAPDF_V}.tar.gz" -O- | tar xzf - + cd LHAPDF-${LHAPDF_V} + # add missing header + patch -l -p0 <> ${GITHUB_ENV} + command -v pkgconf + # show LHAPDF's .pc file + pkg-config lhapdf --path + cat $(pkg-config lhapdf --path) + echo ${PKG_CONFIG_PATH} echo "PKG_CONFIG_PATH=/ucrt64/lib/pkgconfig:${PKG_CONFIG_PATH}" >> ${GITHUB_ENV} - echo "${PKG_CONFIG_PATH}" + - name: Patch pineappl_cli/pyproject.toml + run: | + # on Windows we can't build with all features (yet) + sed -i '/all-features/d' pineappl_cli/pyproject.toml - name: Build wheels run: - maturin build --release --out dist --find-interpreter --manifest-path pineappl_cli/Cargo.toml --target ${{ matrix.target }} + maturin build --release --out dist --find-interpreter --manifest-path pineappl_cli/Cargo.toml --features=static -- -Ctarget-feature=+crt-static - name: Upload wheels uses: actions/upload-artifact@v4 with: - name: ${{ github.job }}-${{ matrix.target }} + name: ${{ github.job }} path: dist diff --git a/.github/workflows/msrv.yml b/.github/workflows/msrv.yml index cc8d68158..b5354a69b 100644 --- a/.github/workflows/msrv.yml +++ b/.github/workflows/msrv.yml @@ -5,6 +5,7 @@ on: branches-ignore: - pycli - bump-pyo3-version + - windows-cli-wheels env: CARGO_TERM_COLOR: always diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 84c6d9b05..7080514bf 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -4,6 +4,7 @@ on: push: branches-ignore: - pycli + - windows-cli-wheels jobs: test: diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 9ddec0b83..8fe9202af 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -5,6 +5,7 @@ on: branches-ignore: - pycli - bump-pyo3-version + - windows-cli-wheels defaults: run: