x86_64 architecture support (required for Solana program compatibility)
Git (for cloning repositories with submodules)
The non-x86_64 toolchains are incompatible due to memory layout differences between Solana program (BPF) and aarch64. Using non-x86_64 architectures will fail at runtime with deserialization errors like InvalidSize.
Install both the latest stable and 1.76.0 x86_64 toolchains:
# Replace '1.85.0' with your preferred latest stable versionrustup install 1.85.0-x86_64-apple-darwin 1.76.0-x86_64-apple-darwin --force-non-host
You must install both 1.76.0-x86_64 and your latest stable Rust version. The 1.76.0 toolchain is required for compatibility with Solana program builds.
3
Set Default Toolchain
Set the x86_64 toolchain as default for your project:
rustup override set 1.85.0-x86_64-apple-darwin
4
Verify Installation
Check that you’re using the correct toolchain:
rustc --version --verbose
You should see host: x86_64-apple-darwin in the output.
Install both the latest stable and 1.76.0 x86_64 toolchains:
# Replace '1.85.0' with your preferred latest stable versionrustup install 1.85.0-x86_64-unknown-linux-gnu 1.76.0-x86_64-unknown-linux-gnu --force-non-host
You must install both 1.76.0-x86_64 and your latest stable Rust version. The 1.76.0 toolchain is required for compatibility with Solana program builds.
2
Set Default Toolchain
Set the x86_64 toolchain as default:
rustup override set 1.85.0-x86_64-unknown-linux-gnu
3
Verify Installation
Check that you’re using the correct toolchain:
rustc --version --verbose
You should see host: x86_64-unknown-linux-gnu in the output.