-
Notifications
You must be signed in to change notification settings - Fork 201
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
Installation via brew fails on M1 Macs #1467
Comments
Thanks for reporting! It looks like graalvm is not support in jabba, which is used underneath in coursier: https://github.com/shyiko/jabba/blob/master/index.json arm64 architecture only has jdk currently. It also looks like it's graalvm is not supported on arm64? oracle/graal#2666 Probably it would be best to use normal jdk currently, though I am not up to date on specifics of the new apple chipsets. |
Bloop also does not install on arm64 Linux hosts using AdoptOpenJDK 8:
My environment:
|
I think I know what's going on. Homebrew install uses the graalvm-native-image by default, which is not possible to use on arm. We should probably detect it an install jar based launcher in this case. The workaround currently is to use coursier to install it: It would be best to fix it in https://github.com/scalacenter/homebrew-bloop/blob/master/bloop.rb to detect the system architecture and run the different installer in that case. I don't have a Mac to test it out, so any help would be appreciated. |
Just adding that I haven't used Homebrew to install Coursier on Linux. Used the native binary directly and then |
The default |
Reproduced this issues on a Mac M1 via Homebrew installation. This file is been used as an index for the JVM to pull https://raw.githubusercontent.com/shyiko/jabba/master/index.json however, there is no such version 19.3, instead it has a minor version
this breaks the installation. any suggestion? |
this PR looks related |
Installation is still failing on M1 (same error) |
Graal still doesn't seem to work for M1 (oracle/graal#2666) so best to use |
Thank you for the workaround will try. What are the differences between |
|
Hi! Any updates since oracle/graal#2666 (comment)? What's the recommended way to compile bloop with an existing GraalVM installation? |
Most likely we would only need to update once the release of GraalVM is stable, is it out yet? It should be possible use coursier to boostrap bloop or bloop-jvm - https://get-coursier.io/docs/cli-bootstrap#graalvm-native-image Though I have not tried myself. |
GraalVM 22.1.0 with Apple Silicon native image (still preview) support was recently released. |
Interesting! I think we would require a github runner for Apple Silicon to create binary, but maybe it's possible to produce it also using coursier? There is no runner currently available from what I know, but if the demand is high we can try and set something up with some help. |
Unfortunately this is very true and it is a blocker for numerous OSS projects as the only solution right now seems to be selfhosted runner. It could be possible to bootstrap native version with coursier on M1 macs, just need to adjust the command line, so, that coursier will be able to find the version for darwin-aarch64 in JVM index. I will try it myself, when I find a time window for this. |
For now coursier is a no go, at least because of this oracle/graal#4526 There were also issues that VM resolution in coursier bootstrap is not working correctly on M1 ( For one other application coursier had no such issues, when used from sbt and sbt-native-image plugin. It is bootstrap cli exclusive thing. |
And update on another issue, that JDK can't be located in index. It is because for 22.1.0 default graalvm tag is not populated, only these are available in index: "jdk@graalvm-java11": {
"22.1.0": "tgz+https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.1.0/graalvm-ce-java11-darwin-aarch64-22.1.0.tar.gz"
},
"jdk@graalvm-java17": {
"22.1.0": "tgz+https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.1.0/graalvm-ce-java17-darwin-aarch64-22.1.0.tar.gz"
}, And here is coursier issue, that states, that currently tag is hardcoded coursier/coursier#1789 (comment) So, I needed a workaround of my own {
"darwin": {
"arm64": {
"jdk@graalvm": {
"22.1.0": "tgz+https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-22.1.0/graalvm-ce-java17-darwin-aarch64-22.1.0.tar.gz"
}
}
}
} |
I was able to install bloop a couple of days ago on Apple M1 chip. Below are the steps, in case it's helpful for someone:
Step 1: Install GraalVM CE 22.2.0-dev build Graal introduced a support for Apple M1 in version 22.2. As of today, that version is still in the I downloaded Then follow the Installation on macOS Platforms After that, I should see:
Step 2: Install bloop
And then I have this:
|
Looks like this is now possible? |
Looks like it's only for large runners, can we even use them in open source projects? |
I guess it ultimately depends on the team/Org
|
Looks like we would need to wait still a bit to enable it for Bloop or try to generate the image in another org where we have a self hosted runner. |
Imho a more reliable way would be to push for coursier/coursier#2301 (moving Brew infrastructure has plenty of Mac runners to bottle formulas (build binaries), and is very trusted and comptent to maintain package in working condition. |
I think this should now work with all the recent changes to coursier |
Trying to install the latest bloop via Homebrew on a M1 MBP fails:
The text was updated successfully, but these errors were encountered: