-
Notifications
You must be signed in to change notification settings - Fork 132
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Big Sur / M1: Multiple versions fail with "machine arm64-apple
not recognised"
#210
Comments
The answer is that all the versions that failed are old versions of their respective Ruby families and the build includes an old Later versions, (e.g. 2.7.3, 2.6.7) build with an updated config.sub. If I build these older versions from source I can copy in a config.sub from the source of a newer version, and I am interested in whether it is possible to override what |
Update: it is possible to override the result of config.sub by using Specifying the build argument made this error go away. I passed |
Even if you are able to build the desired ruby version with a M1-based CPU chances are building native-gems will fails too and more generally speaking any dependencies with other languages (nodejs, python, etc.) that has C binding, because ARM architecture is not as well supported as x86 in application development environments. |
@noraj you seem to be implying that it's not worth getting In fact all the native dependencies that I've encountered in Ruby or React-Native have either fixed their M1 problems or have a one-line fix that appears at the top of the Google search results. Literally type in the error to Google and find the fix to paste into the terminal. A maximum of 5 minutes each. On the other hand, this issue delayed me switching my primary work to an M1 machine by a month with full days spent on Google and debugging in the terminal. This is the problem, the issues with native dependencies are trivial by comparison. That said, I've noticed that most of my colleagues on M1 do not have this issue and I'm perplexed about what the difference could be. |
@iftheshoefritz don't use an M1 then ? |
@iftheshoefritz I had to help someone with a M1 mac but asdf-ruby was only one of the many problems. Another problem due to the ARM architecture is virtualization. And even problems with all macs (arm and x86) is due to the fact that macos is using bash 3.2 while many bash script expect you to have a least bash 4.0. macs are more suited for VIPs than power user. I'd suggest having a Dell, Lenovo or HP for a pro laptop and then whatever Linux distribution or even windows rather than a mac if you are a power user. But that's totally off-topic. |
@airtonix what a bizarre comment. I'm not complaining about using M1, I'm ecstatic with it. |
Not bizare at all tbh. if you're wasting days and days because: "M1" - then stop using an M1... go back to using a powerful intel machine. Until I see the react-native team officially announce support for M1, i'll consider the M1 a risk. |
@iftheshoefritz As ASDF uses ruby-build to perform the installation, if you're still having issues, you may want to look over there. Would you mind closing the issue if you're otherwise done with it? |
Closing this. I'm not on top of the problem anymore but since 2.7 has reached eol and newer versions of ruby do install without problems, it seems obsolete. |
For anyone else experiencing similar issues, please see the ruby-build project specifically, and open any issues there if necessary. As @SeanSith pointed out asdf-ruby uses ruby-build for everything, so we can only provide version/architecture combos supported by ruby-build itself. |
I'm on an M1 MBP 13". All the Ruby versions I've tried except v3 have failed to install:
Same error with 2.6.3, 2.6.5, 2.7.1, 2.7.2.
But with 3.0.0:
Why is only 3.0.0 succeeding?
The text was updated successfully, but these errors were encountered: