It's recommended to set RUST_SRC_PATH for speed up, but racer detects it automatically if you don't set it. % export RUST_SRC_PATH=$(rustc -print sysroot)/lib/rustlib/src/rust/library or % export RUST_SRC_PATH="$(rustc -print sysroot)/lib/rustlib/src/rust/src" (older) (Optional) Set RUST_SRC_PATH environment variable to point to the 'src' dir in the Rust source installationĮ.g. (rustup case) Add a nightly toolchain build and install nightly sources too If you want to use racer with multiple release channels (Rust has 3 release channels: stable, beta and nightly), you have to also download Rust source code for each release channel you install.Į.g. Rustup will keep the sources in sync with the toolchain if you run rustup update. target/release/ directory to your PATHĪutomatically via rustup and run rustup component add rust-src in order to install the source to $(rustc -print sysroot)/lib/rustlib/src/rust/library (or $(rustc -print sysroot)/lib/rustlib/src/rust/src in older toolchains). This can be done by moving it to a directory already in your PATH (i.e. target/release/racerĪdd the binary to your PATH. From sourcesĬd racer cargo +nightly build -release. Internally, racer calls cargo as a CLI tool, so please make sure cargo is installed With cargo installĪs mentioned in the command output, don't forget to add the installation directory to your PATH. Toolchain, which is necessary to compile Racer. Note: The second command adds the rustc-dev component to the nightly Rustup component add rustc-dev -toolchain=nightly
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |