diff --git a/ci/scripts/python_wheel_windows_build.bat b/ci/scripts/python_wheel_windows_build.bat index 80270a84c452c..98afba2911858 100644 --- a/ci/scripts/python_wheel_windows_build.bat +++ b/ci/scripts/python_wheel_windows_build.bat @@ -121,7 +121,11 @@ set ARROW_HOME=C:\arrow-dist set CMAKE_PREFIX_PATH=C:\arrow-dist pushd C:\arrow\python -@REM bundle the msvc runtime -cp "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Redist\MSVC\14.16.27012\x64\Microsoft.VC141.CRT\msvcp140.dll" pyarrow\ +@REM build wheel python setup.py bdist_wheel || exit /B 1 + +@REM Repair the wheel with delvewheel +pip install delvewheel || exit /B 1 +delvewheel show || exit /B 1 +delvewheel repair -L . dist\pyarrow-*.whl -w repaired_wheels || exit /B 1 popd diff --git a/ci/scripts/python_wheel_windows_test.bat b/ci/scripts/python_wheel_windows_test.bat index cae1b7ef32aa5..c82f8675c8660 100755 --- a/ci/scripts/python_wheel_windows_test.bat +++ b/ci/scripts/python_wheel_windows_test.bat @@ -39,7 +39,7 @@ set PARQUET_TEST_DATA=C:\arrow\submodules\parquet-testing\data pip install -r C:\arrow\python\requirements-wheel-test.txt || exit /B 1 @REM Install the built wheels -python -m pip install --no-index --find-links=C:\arrow\python\dist\ pyarrow || exit /B 1 +python -m pip install --no-index --find-links=C:\arrow\python\repaired_wheels pyarrow || exit /B 1 @REM Test that the modules are importable python -c "import pyarrow" || exit /B 1 diff --git a/dev/tasks/python-wheels/github.windows.yml b/dev/tasks/python-wheels/github.windows.yml index 0db4047951d2b..d3db9ec22c39b 100644 --- a/dev/tasks/python-wheels/github.windows.yml +++ b/dev/tasks/python-wheels/github.windows.yml @@ -64,8 +64,8 @@ jobs: cd arrow archery docker run python-wheel-windows-test - {{ macros.github_upload_releases("arrow/python/dist/*.whl")|indent }} - {{ macros.github_upload_gemfury("arrow/python/dist/*.whl")|indent }} + {{ macros.github_upload_releases("arrow/python/repaired_wheels/*.whl")|indent }} + {{ macros.github_upload_gemfury("arrow/python/repaired_wheels/*.whl")|indent }} {% if arrow.is_default_branch() %} - name: Push Docker Image