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

New install of racer failing, suspected RUST_SRC_PATH problem #1133

Closed
thor314 opened this issue Oct 6, 2020 · 3 comments
Closed

New install of racer failing, suspected RUST_SRC_PATH problem #1133

thor314 opened this issue Oct 6, 2020 · 3 comments

Comments

@thor314
Copy link

thor314 commented Oct 6, 2020

New install of racer, failing to work as intended. Is this an export RUST_SRC_PATH=blah in .zshrc type fix?
after on command line:
racer complete std::io::B

racer-debug returns:

$ cd /home/thor/r/imp/
$ export CARGO_HOME=/home/thor/.cargo
$ export RUST_SRC_PATH=/home/thor/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src
$ /home/thor/.cargo/bin/racer complete 3 0 /home/thor/r/imp/src/main.rs /tmp/racerpJLTIq

This command terminated with exit code 1.

stdout:

Unable to find libstd under RUST_SRC_PATH. N.B. RUST_SRC_PATH variable needs to point to the *src* directory inside a rust checkout e.g. "/home/foouser/src/rust/src". Current value ""/home/thor/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libstd""

Process *async-racer* exited abnormally with code 1

stderr:


Process *async-racer* stderr finished
@chama-chomo
Copy link

same here

racer 2.1.39
rustup 1.22.1
nightly-x86_64-unknown-linux-gnu - Up to date : 1.49.0-nightly (91a79fb29 2020-10-07)
Manjaro Linux

@chama-chomo
Copy link

@thor314 can you try this? see #1117

export RUST_SRC_PATH="$(rustc --print sysroot)/lib/rustlib/src/rust/library"

@thor314
Copy link
Author

thor314 commented Oct 8, 2020

@chama-chomo that appears to work. Much obliged.

@thor314 thor314 closed this as completed Oct 8, 2020
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

2 participants