Skip to content

Commit e3d8127

Browse files
committed
doc/rust: Simplify by allowing any toolchain
1 parent 4c28bcf commit e3d8127

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

doc/doxygen/src/using-rust.md

+10-8
Original file line numberDiff line numberDiff line change
@@ -106,21 +106,23 @@ Toolchain {#toolchain}
106106

107107
To install the necessary Rust components, it is easiest use [**rustup**, installed as described on its website].
108108

109-
Using Rust on RIOT needs the latest stable version of Rust.
110-
111-
Make sure you have the stable **toolchain**
112-
and the core library for the CPU (**target**) of your choice available:
109+
While the compiler installed through rustup can generate code for all supported platforms,
110+
you will still need to download the core libraries for your **target**:
113111

114112
```
115-
$ rustup toolchain add stable
116-
$ rustup target add thumbv7m-none-eabi --toolchain stable
113+
$ rustup target add thumbv7m-none-eabi
117114
```
118115

119116
Substitute thumbv7m-none-eabi with the value of `RUST_TARGET`
120117
in the output of `make info-build` of an application that has your current board selected
121118
(or just add it later whenever the Rust compiler complains about not finding the core library for a given target).
122-
Using a beta or nightly will work just as well,
123-
but you may need to set `CARGO_CHANNEL=nightly` on your shell or in your Makefiles.
119+
120+
If you prefer to use other **targets** than the default "stable"
121+
(popular choices are "beta", "nightly" or a particular nightly such as "nightly-2022-10-14"),
122+
you'll need to make sure that the core library is available for that target
123+
by running the `target add` line with a parameter of `--toolchain nightly` or similar.
124+
Note that some tests force the toolchain to "stable",
125+
so you'll need to either have that available or override the `CARGO_CHANNEL` make variable.
124126

125127

126128
While Rust comes with its own [cargo] dependency tracker for any Rust code,

0 commit comments

Comments
 (0)