Commit fe42499
committed
[Python][Packaging] Set MACOSX_DEPLOYMENT_TARGET default before building wheel platform tag
In ci/scripts/python_wheel_macos_build.sh the wheel platform tag
_PYTHON_HOST_PLATFORM was assembled from MACOSX_DEPLOYMENT_TARGET one line
before that variable's :-12.0 default was applied. When the script runs
without MACOSX_DEPLOYMENT_TARGET already exported (for example a manual or
local macOS build), the interpolation yields a malformed tag with an empty
version component (macosx--<arch>), while the C++ libraries and the wheel are
actually built for 12.0. That produces an inconsistent, invalid platform tag
on the built wheel.
Swap the two lines so the default is set first and the platform tag is derived
from the resolved value. When MACOSX_DEPLOYMENT_TARGET is already set (as in
the packaging CI, which exports it as a top-level env var), the output is
unchanged, so there is no behavior change for existing jobs.
Verified the two lines in isolation with the variable unset: before the change
_PYTHON_HOST_PLATFORM=macosx--x86_64, after the change macosx-12.0-x86_64. The
full macOS wheel build was not run (no Arrow C++ toolchain available locally).1 parent 6378639 commit fe42499
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
37 | 36 | | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| |||
0 commit comments