-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Dockerfile for aarch64 #2446
Comments
I got around the |
I have the same issue and it seems that Rust Solana toolchain is x86_64 getting downloaded even on aarch64 Linux system. This is what I see in my aarch64 container (running on M2 Mac):
What I need to figure out now is why is that x86_64 toolchain downloaded - whether it's Anchor or Solana scripts doing that. |
OK, it's cargo-sbf-build doing that. It installs https://github.com/solana-labs/platform-tools here: And there are no binaries for linux-aarch64, the only aarch64 build is for macOS: https://github.com/solana-labs/platform-tools/releases/tag/v1.37 There is an issue about that anza-xyz/platform-tools#66. |
I'm on an M2 Mac, and I've been trying to create a Dockerfile for aarch64, because the
anchor build
command takes over 15 minutes on my machine when using the current amd64 image.I figured out how to build the Solana CLI tools from source (there's no aarch64 Linux binary), but now I'm stuck with the following error (when running
anchor build
):apt-file search libz.so.1
told me it belongs tozlib1g
, but I already have it installed (the aarch64 version).I managed to resolve the previous error
by running
but maybe that wasn't the correct approach?
Anyway, here's my Dockerfile (based on the official amd64 one):
The last command (
anchor build
) causes the above-mentioned errors.The reason I'm doing this is because I want to make Solana development easier with my command-line tool create-solana-starter (a Grizzlython hackathon submission). Installing all the needed tools (Rust, Solana, Anchor, etc.) locally can be a hassle, so I would like to give users the option to use Docker instead.
Would appreciate any advice on how to proceed from here!
The text was updated successfully, but these errors were encountered: