최근에 녹 음 언어를 this site (Linux 64 비트)에서 다운로드하여 압축을 풉니 다. 녹 생성기가 'std'에 대한 크레이트를 찾을 수 없습니다
난 후 다운로드install.sh
에 주어진 스크립트를 사용하여 녹 설치 :
[email protected]:~# /root/rust-1.9.0-x86_64-unknown-linux-gnu/install.sh
install: uninstalling component 'rustc'
install: creating uninstall script at /usr/local/lib/rustlib/uninstall.sh
install: installing component 'rustc'
install: installing component 'rust-std-x86_64-unknown-linux-gnu'
install: installing component 'rust-docs'
install: installing component 'cargo'
Rust is ready to roll.
내가화물과 함께 상자를 설치하려고하지만,이 오류로 실행 계속 :
[email protected]:~# cargo install racer
Updating registry `https://github.com/rust-lang/crates.io-index`
Compiling winapi v0.2.7
Compiling bitflags v0.5.0
error: can't find crate for `std` [E0463]
error: aborting due to previous error
Build failed, waiting for other jobs to finish...
error: can't find crate for `std` [E0463]
error: aborting due to previous error
error: failed to compile `racer v1.2.10`, intermediate artifacts can be found at `/root/target-install`
cargo install cargo-edit
위와 같은 결과로 실패했습니다. 따라서 특정 패키지에만 국한되지 않습니다.
심지어 간단한 프로그램 퍼팅 : hello.rs
및 컴파일되지 않습니다 rustc hello.rs
을 실행라는 이름의 파일에
fn main() {
println!("Hello, world!");
}
을; 같은 오류가 발생합니다 : error: can't find crate for 'std' [E0463]
.
다운로드에는 rust-std-x86_64-unknown-linux-gnu
이라는 디렉토리가 있습니다.이 디렉토리는 std 크레이트입니다. 표준 상자를 찾으려고 할 때이 디렉토리를 찾으려면 rustc에게 어떻게 지시해야합니까?
가 컴파일 할 수 녹 코드? 예를 들어,'cargo install cargo-edit'를 시도해보십시오. Racer가 std의 소스 코드를 필요로하지만 오류 메시지는 * 컴파일러가 std * 바이너리 *를 찾을 수 없기 때문에 Racer 컴파일러가 될 수 없습니다. – delnan
@delnan : 분명히 "안녕하세요, 세상!" 컴파일되지 않기 때문에, 여기서 문제는'stc' 상자가 어디에 있는지를 알지 못하는'rustc'이라는 것에 동의하는 경향이 있습니다. –
[rustup] (https://www.rustup.rs/)을 사용해 볼 수 있습니다. –