Skip to content

Commit

Permalink
fix delvewheel invocation, restore dir cleaning [wheel build]
Browse files Browse the repository at this point in the history
  • Loading branch information
mattip committed Feb 8, 2024
1 parent 621db87 commit 8f2e11c
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ DYLD_LIBRARY_PATH="$DYLD_LIBRARY_PATH:/$PWD/.openblas/lib"
# This does not work, use CIBW_ENVIRONMENT_WINDOWS
environment = {PKG_CONFIG_PATH="./.openblas"}
config-settings = "setup-args=--vsenv setup-args=-Dallow-noblas=false build-dir=build"
repair-wheel-command = "bash ./tools/wheels/repair_windows.sh {wheel} {dest_dir}"
repair-wheel-command = "bash -el ./tools/wheels/repair_windows.sh {wheel} {dest_dir}"

[[tool.cibuildwheel.overrides]]
select = "*-win32"
Expand Down
1 change: 0 additions & 1 deletion tools/ci/cirrus_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ macosx_arm64_task:
CIBW_BUILD: cp310-* cp311-*
- env:
CIRRUS_CLONE_SUBMODULES: true
CIBW_PRERELEASE_PYTHONS: True
CIBW_BUILD: cp312-*
env:
PATH: /usr/local/lib:/usr/local/include:$PATH
Expand Down
1 change: 1 addition & 0 deletions tools/wheels/cibw_before_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ fi
if [[ "$INSTALL_OPENBLAS" = "true" ]] ; then
echo PKG_CONFIG_PATH $PKG_CONFIG_PATH
PKG_CONFIG_PATH=$PROJECT_DIR/.openblas
rm -rf $PKG_CONFIG_PATH
mkdir -p $PKG_CONFIG_PATH
python -m pip install scipy-openblas64
python -c "import scipy_openblas64; print(scipy_openblas64.get_pkg_config())" > $PKG_CONFIG_PATH/scipy-openblas.pc
Expand Down
4 changes: 3 additions & 1 deletion tools/wheels/repair_windows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ DEST_DIR="$2"

# create a temporary directory in the destination folder and unpack the wheel
# into there
cwd=$PWD

pushd $DEST_DIR
mkdir -p tmp
pushd tmp
Expand All @@ -29,4 +31,4 @@ rm -rf tmp

# the libopenblas.dll is placed into this directory in the cibw_before_build
# script.
delvewheel repair --add-path /c/opt/64/bin -w $DEST_DIR $WHEEL
delvewheel repair --add-path $cwd/.openblas/lib -w $DEST_DIR $WHEEL

0 comments on commit 8f2e11c

Please sign in to comment.