Skip to content

Commit 711cbfc

Browse files
vireshkojeda
authored andcommitted
docs: rust: Clarify that 'rustup override' applies to build directory
'rustup override' is required to be set for the build directory and not necessarily the kernel source tree (unless the build directory is its subdir). Clarify the same in the Quick Start guide. Signed-off-by: Viresh Kumar <[email protected]> Reviewed-by: Benno Lossin <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Originally-pointed-out-by: Masahiro Yamada <[email protected]> Link: f2238e7 Link: https://lore.kernel.org/r/e2b943eca92abebbf035447b3569f09a7176c770.1702366951.git.viresh.kumar@linaro.org [ Reworded and fixed quotes for `--path` and `set`. ] Signed-off-by: Miguel Ojeda <[email protected]>
1 parent be412ba commit 711cbfc

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

Documentation/rust/quick-start.rst

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,18 @@ A particular version of the Rust compiler is required. Newer versions may or
3333
may not work because, for the moment, the kernel depends on some unstable
3434
Rust features.
3535

36-
If ``rustup`` is being used, enter the checked out source code directory
37-
and run::
36+
If ``rustup`` is being used, enter the kernel build directory (or use
37+
``--path=<build-dir>`` argument to the ``set`` sub-command) and run::
3838

3939
rustup override set $(scripts/min-tool-version.sh rustc)
4040

4141
This will configure your working directory to use the correct version of
42-
``rustc`` without affecting your default toolchain. If you are not using
43-
``rustup``, fetch a standalone installer from:
42+
``rustc`` without affecting your default toolchain.
43+
44+
Note that the override applies to the current working directory (and its
45+
sub-directories).
46+
47+
If you are not using ``rustup``, fetch a standalone installer from:
4448

4549
https://forge.rust-lang.org/infra/other-installation-methods.html#standalone
4650

0 commit comments

Comments
 (0)