-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Consider using a rust-toolchain.toml
file
#25603
Comments
sounds like a good idea! |
The plan is to split one huge PR into several smaller:
|
I'm thinking should we use the pattern below to replace source ci/rust-version.sh stable
... (omit)
cargo +"$rust_stable"
the concern is that if someone set |
I think the main idea of using |
Switching this from "not planned" to "closed"; we still depend on the custom cargo script for some aspects (ie running Any further work to try to reduce usage of this scripts can probably take place in new PR's / issue(s) |
Problem
Solana depends intimately on the particular
rustc
version used. One example of this was solana-labs/rbpf@5394026, where before that change inrbpf
was merged, Solana would segfault when compiled with the wrongrustc
version.However, for the default approach of building a Rust project (
cargo build
),rustup
uses the system-wide default toolchain, not the one suitable for the particular Solana release. Fortunately, the right Rust version is recorded in the repository:solana/ci/rust-version.sh
Line 21 in 24634b6
rustup
’scargo
proxy binary.Proposed Solution
Add a
rust-toolchain
orrust-toolchain.toml
file to pin the stable toolchain usingrustup
’s standard mechanism. The existingci/rust-version.sh
can still manage the nightly toolchain. As far as I am aware, there is no standardized way to manage multiple toolchains.@mvines, you seem to most often update the Rust version, what do you think?
The text was updated successfully, but these errors were encountered: