Skip to content

Commit 38f022b

Browse files
committed
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. Link: https://packages.ubuntu.com/search?keywords=rustc-1 Link: https://packages.ubuntu.com/search?keywords=bindgen-0 Cc: Zixing Liu <[email protected]> Cc: William Grant <[email protected]> Reviewed-by: Kees Cook <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Miguel Ojeda <[email protected]>
1 parent 8cf0b93 commit 38f022b

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Documentation/rust/quick-start.rst

+17
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,23 @@ they should generally work out of the box, e.g.::
8787
zypper install rust rust1.79-src rust-bindgen clang
8888

8989

90+
Ubuntu
91+
******
92+
93+
Ubuntu LTS and non-LTS (interim) releases provide recent Rust releases and thus
94+
they should generally work out of the box, e.g.::
95+
96+
apt install rustc-1.80 rust-1.80-src bindgen-0.65 rustfmt-1.80 rust-1.80-clippy
97+
98+
``RUST_LIB_SRC`` needs to be set when using the versioned packages, e.g.::
99+
100+
RUST_LIB_SRC=/usr/src/rustc-$(rustc-1.80 --version | cut -d' ' -f2)/library
101+
102+
In addition, ``bindgen-0.65`` is available in newer releases (24.04 LTS and
103+
24.10), but it may not be available in older ones (20.04 LTS and 22.04 LTS),
104+
thus ``bindgen`` may need to be built manually (please see below).
105+
106+
90107
Requirements: Building
91108
----------------------
92109

0 commit comments

Comments
 (0)