Repository navigation
macOS wheels: support macOS 12+ on Apple Silicon - #165
Merged
Merged
Conversation
The wheels bundle libomp, so they can't support an older macOS than it does, and wheels.yml took the deployment target from Homebrew's libomp, which is built for the runner's macOS. Since the arm64 job moved to macos-15, the arm64 wheels have needed macOS 15 (macosx_15_0_arm64 from 10.5.1.1), and pip on macOS 12 to 14 arm64 builds the sdist instead. Take llvm-openmp from conda-forge (it supports macOS 11.0 and later) through micromamba, as scikit-learn does, and pin the deployment target per job: 12.0 on arm64, as SciPy and scikit-learn use, and 14.0, as now, on x86_64. suitesparse.sh takes the libomp prefix in LIBOMP_PREFIX (BREW_LIBOMP=1 still means Homebrew's) and adds an rpath to it, since conda-forge's libomp has the install name @rpath/libomp.dylib.
The pin is on the version only, so print the package list, which has the build string, next to the library's minimum macOS.
Member
Author
|
I'm happy to defer build things to agents who are better at it than I am. Merging. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Since 10.5.1.1 the Apple Silicon wheels are tagged
macosx_15_0_arm64, sopip install suitesparse-graphblason an M1/M2/M3 Mac running macOS 12, 13 or 14 downloads the sdist and tries to compile GraphBLAS. The tag was never a choice.wheels.ymlsetMACOSX_DEPLOYMENT_TARGETfrom theminosof Homebrew's libomp. Homebrew builds libomp for the runner's macOS, and that became 15 when the arm64 job moved tomacos-15.The second commit logs the llvm-openmp build string and its
minosin the job log, since the pin is on the version only.Evidence
macosx_15_0_arm64andmacosx_14_0_x86_64wheels. 10.5.1.0 and earlier hadmacosx_14_0_arm64.minos 12.0, delocate keeps themacosx_12_0_arm64tag, and the wheel's tests pass with the bundled libomp (OpenMP on, 18 threads).Merge Danger
Door: two-way for the repo, since a revert restores Homebrew's libomp. A release is different: once a
macosx_12_0_arm64wheel is on PyPI, pip on macOS 12 to 14 installs it instead of the sdist. If it were broken there, the fix would be a yank or a post release.Blast Radius: macOS wheels.
Every macOS wheel, on both arches, bundles conda-forge's OpenMP runtime instead of Homebrew's. Linux, Windows, Pyodide and conda-forge packages are unaffected.