Conversation
Signed-off-by: daquexian <daquexian566@gmail.com>
Signed-off-by: daquexian <daquexian566@gmail.com>
|
Thank you for the contribution! Please allow me to reopen this PR to trigger release CIs |
jcwchen
left a comment
There was a problem hiding this comment.
Overall looks good to me. I also tested this universal2 wheel on my Mac (non M1/M2) and it worked well.
| python setup.py bdist_wheel -p macosx_10_12_${{ matrix.target-architecture }} --weekly_build | ||
| else | ||
| python setup.py bdist_wheel -p macosx_10_12_x86_64 | ||
| python setup.py bdist_wheel -p macosx_10_12_${{ matrix.target-architecture }} |
There was a problem hiding this comment.
nit: not sure whether we want to use macosx_10_12_ for universal2 as well. Probably we can assume only 10.15+ users will try universal2 wheel.
There was a problem hiding this comment.
Thanks for your review! It is what I ignored.
What's the reason for choosing 10.15? The minimum macos version that can run on apple silicon chips seems 11. Maybe we can use macosx_11_0_.
There was a problem hiding this comment.
Good point. macosx_11_0_ looks better. Thanks!
There was a problem hiding this comment.
I updated the code and it's a little strange that CI fails. I'll fix it tomorrow.
There was a problem hiding this comment.
@jcwchen I found that python3.7 is incompatible with macosx_11_0_.
$ python3.7 -m pip install onnx-1.12.0-cp37-cp37m-macosx_11_0_x86_64.whl
ERROR: onnx-1.12.0-cp37-cp37m-macosx_11_0_x86_64.whl is not a supported wheel on this platform.
$ python3.7 -m pip install onnx-1.12.0-cp37-cp37m-macosx_10_15_x86_64.whl
Processing ...
$ python3.8 -m pip install onnx-1.12.0-cp38-cp38-macosx_11_0_x86_64.whl
Processing ...So I prefer keeping the versions of x86_64 and universal2 wheels the same. It is also what numpy does:
896baec to
f8b3257
Compare
* build universal2 Signed-off-by: daquexian <daquexian566@gmail.com> * support both universal2 and x86_64 Signed-off-by: daquexian <daquexian566@gmail.com> Signed-off-by: daquexian <daquexian566@gmail.com> Co-authored-by: Chun-Wei Chen <jacky82226@gmail.com>
* build universal2 Signed-off-by: daquexian <daquexian566@gmail.com> * support both universal2 and x86_64 Signed-off-by: daquexian <daquexian566@gmail.com> Signed-off-by: daquexian <daquexian566@gmail.com> Co-authored-by: Chun-Wei Chen <jacky82226@gmail.com>
* build universal2 Signed-off-by: daquexian <daquexian566@gmail.com> * support both universal2 and x86_64 Signed-off-by: daquexian <daquexian566@gmail.com> Signed-off-by: daquexian <daquexian566@gmail.com> Co-authored-by: Chun-Wei Chen <jacky82226@gmail.com>

Description
Fixes #4436
It is easier than I thought to build macos universal2 binaries. A proper
CMAKE_OSX_ARCHITECTURESis all we need 😂I have tested the universal2 wheel on my m1 machine.