Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rustup is not installed at /home/user/.cargo #471

Closed
leshow opened this issue May 16, 2016 · 11 comments
Closed

rustup is not installed at /home/user/.cargo #471

leshow opened this issue May 16, 2016 · 11 comments

Comments

@leshow
Copy link

leshow commented May 16, 2016

>  ~  rustup update
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
info: syncing channel updates for 'nightly-x86_64-unknown-linux-gnu'
error: rustup is not installed at '/home/leshow/.cargo'
>  ~  rustup --version
rustup 0.1.12 (c6e430a 2016-05-12)

Rustup appears to work properly, i can download toolchains and swap them, but it throws this error on update.

i previously had this error with 0.1.11, and read that deleting .multirust was the solution. I deleted .cargo and .multirust and installed rustup 0.1.12, the problem persists.

@brson
Copy link
Contributor

brson commented May 17, 2016

This error happens when the file ~/.cargo/bin/multirust does not exist (the name of this file is historical and well be phased out soon). Do you have that file?

@leshow
Copy link
Author

leshow commented May 17, 2016

no, i do not. should i cargo install multirust?

@brson
Copy link
Contributor

brson commented Jun 3, 2016

No don't do that. ~/.cargo/bin/multirust should be installed by rustup. For some reason it isn't for you. Does that file exist immediately after install? Can you identify at what point it disappears?

@leshow
Copy link
Author

leshow commented Jun 3, 2016

I have uninstalled and re-installed rustup multiple times and this file never gets created.

rustup seem to work, but the error still happens every time I update

@brson
Copy link
Contributor

brson commented Jun 23, 2016

I still have no clue what might be happening here, but you might be able to figure out what's going on with strace:

brian@ip-10-145-43-250:~/dev/rustup.rs⟫ strace target/release/rustup-init -y 2>&1 | grep bin/multirust
stat("/home/brian/.multirust/bin/multirust", 0x7ffc3f5985a0) = -1 ENOENT (No such file or directory)
stat("/home/brian/.cargo/bin/multirust", {st_mode=S_IFREG|0755, st_size=6231904, ...}) = 0
unlink("/home/brian/.cargo/bin/multirust") = 0
open("/home/brian/.cargo/bin/multirust", O_WRONLY|O_CREAT|O_TRUNC|O_CLOEXEC, 0666) = 4
chmod("/home/brian/.cargo/bin/multirust", 0775) = 0
stat("/home/brian/.cargo/bin/multirust", {st_mode=S_IFREG|0775, st_size=6231904, ...}) = 0
chmod("/home/brian/.cargo/bin/multirust", 0755) = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/rustup") = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/rustc") = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/rustdoc") = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/cargo") = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/rust-lldb") = 0
link("/home/brian/.cargo/bin/multirust", "/home/brian/.cargo/bin/rust-gdb") = 0

You can see here that bin/multirust is the "main" rustup binary; it's installed first, then rustup, rustc etc are symlinked to it. That rustup works for you means those symlinks must be linking to something. Where do they link to?

@leshow
Copy link
Author

leshow commented Jun 24, 2016

i have installed rustup from src via the AUR see pkgbuild

rustup and multirust are located in /usr/bin, since i don't have a rustup.rs directory checked out, i'm not sure where to run that strace.

@brson
Copy link
Contributor

brson commented Jul 19, 2016

Huh, were you using the AUR build of rustup in the original post? If they are modifying rustup to install to a system dir then that would explain why the self update doesn't see itself as installed.

@jonas-schievink
Copy link

@brson That's whats happening. Will this configuration be supported eventually?

@brson
Copy link
Contributor

brson commented Jul 19, 2016

@jonas-schievink I'd like it to be. I think at the least rustup needs to be compiled so that update does not do a self-update and rustup self update generates an error. Haven't thought about what else will be required.

@brson
Copy link
Contributor

brson commented Jul 19, 2016

Added a bug to compile out self updates #597

@Diggsey
Copy link
Contributor

Diggsey commented May 4, 2017

This has been implemented, any remaining work will be upstream to take advantage of --no-self-update

@Diggsey Diggsey closed this as completed May 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants