Closed
Description
Code
While logged in as root
on Linux::
- Clone the Rust repo
cd rust; ./x.py build
Current output
info: looks like you're trying to run this command as root
and so in order to preserve your $HOME this will now
use vendored sources by default.
error: vendoring required, but vendor directory does not exist.
Run `cargo vendor --sync ./src/tools/rust-analyzer/Cargo.toml --sync ./compiler/rustc_codegen_cranelift/Cargo.toml --sync ./src/bootstrap/Cargo.toml ` to initialize the vendor directory.
Alternatively, use the pre-vendored `rustc-src` dist component.
Traceback (most recent call last):
File "/home/scratch/rust/./x.py", line 29, in <module>
bootstrap.main()
File "/home/scratch/rust/src/bootstrap/bootstrap.py", line 949, in main
bootstrap(args)
File "/home/scratch/rust/src/bootstrap/bootstrap.py", line 896, in bootstrap
build.check_vendored_status()
File "/home/scratch/rust/src/bootstrap/bootstrap.py", line 831, in check_vendored_status
raise Exception("{} not found".format(vendor_dir))
Exception: /home/scratch/rust/vendor not found
Desired output
The suggestion to run cargo vendor
isn't helpful if you don't already have a Rust toolchain installed. That leaves: "Alternatively, use the pre-vendored rustc-src
dist component." It's completely unclear to me what this means or how to do it. Perhaps providing a link to documentation would be useful.
Metadata
Metadata
Assignees
Labels
Area: Messages for errors, warnings, and lintsCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)This issue requires custom config/build for rustc in some way