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

Cannot build xv6-rust: failed to get allocator as a dependency of package #46

Closed
anta40 opened this issue Jan 23, 2022 · 2 comments
Closed

Comments

@anta40
Copy link

anta40 commented Jan 23, 2022

I'm on MacOS Big Sur with the latest nightly Rust installed:

$ rustc --version
rustc 1.60.0-nightly (bfe156467 2022-01-22)

I also already had another tools installed:

$ rustup target add riscv64gc-unknown-none-elf
$ cargo install cargo-binutils
$ rustup component add llvm-tools-preview

Now let's run make:

$ cd xv6-rust/kernel
make
...
...
error: failed to get allocator as a dependency of package kernel v0.1.0 (/Users/andre/Lab/OSDev/xv6-rust/kernel)

Caused by:
failed to load source for dependency allocator

Caused by:
Unable to update /Users/andre/Lab/OSDev/xv6-rust/allocator

Caused by:
failed to read /Users/andre/Lab/OSDev/xv6-rust/allocator/Cargo.toml

Caused by:
No such file or directory (os error 2)
make: *** [kernel] Error 101

@KuangjuX
Copy link
Member

KuangjuX commented Jan 23, 2022

I'm guessing it's because the allocator's code isn't pulled down. Try to execute git submodule update --init --recursive to get the source code of the allocator crate.

@KuangjuX
Copy link
Member

I have updated README.

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