Open
Description
I own a Chromebook Pixel, and use the crosvm (debian) option to do some coding. I tried installing Rust, and the installer placed files in the incorrect location.
Steps
- I looked up the command linked here https://www.rust-lang.org/tools/install
- I'm used to this kind of thing failing without privs, so I added a sudo before the sh and ran it, eg
curl https://sh.rustup.rs -sSf | sudo sh
- The installer displayed something like the following
info: downloading installer
Welcome to Rust!
This will download and install the official compiler for the Rust programming
language, and its package manager, Cargo.
It will add the cargo, rustc, rustup and other commands to Cargo's bin
directory, located at:
/home/pgburt/.cargo/bin
This path will then be added to your PATH environment variable by modifying the
profile files located at:
/home/pgburt/.profile
/home/pgburt/.bash_profile
You can uninstall at any time with rustup self uninstall and these changes will
be reverted.
Current installation options:
default host triple: x86_64-unknown-linux-gnu
default toolchain: stable
modify PATH variable: yes
1) Proceed with installation (default)1) Proceed with installation (default)
2) Customize installation
3) Cancel installation
- I pressed
1
to do the default installation. - The install appeared to succeed, but instructed me to run a script in
$HOME/.cargo/env
to set my PATH. When I tried running that script, I found nothing there. - Trying to run
rustup
showed it wasn't registered.
I expected the install to put everything in my $HOME directory, which should be /home/pgburt
. Instead, it placed the files in /root
.
I was able to fix the problem by moving the directory to my actual $HOME, and running the env script. I got a error: no default toolchain configured
when running rustc after that, so was able to fix by running rustup install stable
which seems to work.
Meta
In lieu of a rustc version, I can run curl https://sh.rustup.rs -sSf | less
and see the value: rustup-init 1.18.3 (3028994 2019-05-22)
ChromeOS: Version 74.0.3729.159 (Official Build) (64-bit)