docs: rust: quick-start: add Ubuntu
Subsystems (2)
Miguel Ojeda
maintainerPATCH 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 it is done for the other distributions.
---
RFC: https://lore.kernel.org/rust-for-linux/[email protected]/
Compared to the RFC, 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 I added a note about that compared to the RFC patch.
Documentation/rust/quick-start.rst | 17 +++++++++++++++++ 1 file changed, 17 insertions(+)
Documentation/rust/quick-start.rst +17 -0
@@ -87,6 +87,23 @@ 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 + +In addition, ``bindgen-0.65`` is available in newer releases (24.04 LTS and +24.10), but it may not be available in older ones (20.04 LTS and 22.04 LTS), +thus ``bindgen`` may need to be built manually (please see below). + + Requirements: Building ----------------------
base-commit: a2f11547052001bd448ccec81dd1e68409078fbb --
2.46.2
Miguel Ojeda
AppliedQuoted 8 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 it is done for the other distributions.
Quoted 6 lines
Cc Zixing Liu <[email protected]>Cc William Grant <[email protected]>Reviewed-by Kees Cook <[email protected]>Signed-off-by Miguel Ojeda <[email protected]>
Applied to rust-next -- thanks everyone!
Cheers,
Miguel