docs: rust: quick-start: add Ubuntu
Subsystems (2)
Miguel Ojeda
maintainerRFC PATCH 1/1 docs: rust: quick-start: add Ubuntu
Ubuntu has changed their maintenance model for Rust toolchains and is now providing recent Rust releases in their releases, including both LTS and non-LTS (interim) releases.
Therefore, add instructions to the Quick Start guide for Ubuntu like for the other distributions.
---
This is a potential patch for the future -- Ubuntu Oracular (future release) works today, but the Rust versioned releases are not backported (yet?). If Ubuntu ends up deciding to backport them, which would be amazing, or at least when they start to appear in an actual release, then we can apply this. Thanks William & Zixing!
Documentation/rust/quick-start.rst | 13 +++++++++++++ 1 file changed, 13 insertions(+)
Documentation/rust/quick-start.rst +13 -0
@@ -87,6 +87,19 @@ they should generally work out of the box, e.g.:: zypper install rust rust1.79-src rust-bindgen clang +Ubuntu +****** + +Ubuntu LTS and non-LTS (interim) releases provide recent Rust releases and thus +they should generally work out of the box, e.g.:: + + apt install rustc-1.80 rust-1.80-src bindgen-0.65 rustfmt-1.80 rust-1.80-clippy + +``RUST_LIB_SRC`` needs to be set when using the versioned packages, e.g.:: + + RUST_LIB_SRC=/usr/src/rustc-$(rustc-1.80 --version | cut -d' ' -f2)/library + + Requirements: Building ----------------------
base-commit: 7c626ce4bae1ac14f60076d00eafe71af30450ba --
2.46.0
Quoted 11 lines · Miguel Ojeda
Ubuntu has changed their maintenance model for Rust toolchains and is now providing recent Rust releases in their releases, including both LTS and non-LTS (interim) releases.
Therefore, add instructions to the Quick Start guide for Ubuntu like for the other distributions.
Cc Zixing Liu <[email protected]>Cc William Grant <[email protected]>Cc Kees Cook <[email protected]>Signed-off-by Miguel Ojeda <[email protected]>
Looks good to me!
Signature · 1 line
Kees Cook
Quoted 6 lines · Miguel Ojeda
This is a potential patch for the future -- Ubuntu Oracular (future release) works today, but the Rust versioned releases are not backported (yet?). If Ubuntu ends up deciding to backport them, which would be amazing, or at least when they start to appear in an actual release, then we can apply this. Thanks William & Zixing!
An update on this: Ubuntu now provides the versioned rustc-* packages in older LTSs (the ones with standard support), which is great!
I can confirm I can build the latest kernel in 20.04 LTS (using a newer LLVM), 22.04 LTS, 24.04 LTS and 24.10.
The bindgen-* versioned packages are not backported (yet?) to the older LTSs, so users need to build bindgen manually in 20.04 LTS and 22.04 LTS. For 24.04 LTS and 24.10, it works with the package. I will add a sentence about that and send the non-RFC patch.
Cheers,
Miguel