-
Notifications
You must be signed in to change notification settings - Fork 40
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
build: pin rust toolchain to specified version in ci and locally #428
Conversation
I have a separate meta comment about In other projects, I've generally relied on the minimum rust version and pinning CI to a specific toolchain version. And, if you declare a given commit as a release branch, then we'd add the corresponding |
We should probably discuss this in the next SVSM call |
Something like this would be helpful for us as well. You'll also want to update the Makefile where it specifies "cargo +nightly" in the bin/test-kernel.elf rule (even better would be if it is possible to have this specified in a Cargo.toml file instead of the makefile?) You should also consider updating scripts/container/opensuse-rust.docker to install the correct version in the container, but this is not technically necessary since rustup will install the correct version for you at build time. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, this requires to specify the stable Rust version at three places. I guess there is no way to specify it in a single place for local and CI builds?
Hey @chris-oo, can you please update this PR to make the CI pass? This is currently blocking the merge. |
Sorry about the delay - I'll fix it up shortly. |
So the |
90e28fa
to
b588ad8
Compare
Pin rust toolchain versions in CI to a specific version, 1.80, along with rust-toolchain.toml. Additionally, add the matching minimum supported rust version to kernel/Cargo.toml. Signed-off-by: Chris Oo <[email protected]>
b588ad8
to
538e507
Compare
Rather than specifying stable as the toolchain to use in CI and locally, instead pin to a specific version of stable. This allows developers to manually fixup lints and issues with new toolchain updates and rev the appropriate versions across the code.
Additionally, add a minimum supported rust version to the main svsm crate, to give a more helpful compiler error when your toolchain does not match.