Closed
Description
Trying to build following the documentation is failing on a Debian sid (aka unstable) in a chroot:
# ./x.py build && sudo ./x.py dist --install
info: looks like you are running this command under `sudo`
and so in order to preserve your $HOME this will now
use vendored sources by default. Note that if this
does not work you should run a normal build first
before running a command like `sudo make install`
downloading https://static.rust-lang.org/dist/2017-04-25/rust-std-beta-x86_64-unknown-linux-gnu.tar.gz
######################################################################## 100.0%
extracting /root/rust/build/cache/2017-04-25/rust-std-beta-x86_64-unknown-linux-gnu.tar.gz
downloading https://static.rust-lang.org/dist/2017-04-25/rustc-beta-x86_64-unknown-linux-gnu.tar.gz
######################################################################## 100.0%
extracting /root/rust/build/cache/2017-04-25/rustc-beta-x86_64-unknown-linux-gnu.tar.gz
downloading https://static.rust-lang.org/dist/2017-04-25/cargo-beta-x86_64-unknown-linux-gnu.tar.gz
######################################################################## 100.0%
extracting /root/rust/build/cache/2017-04-25/cargo-beta-x86_64-unknown-linux-gnu.tar.gz
error: failed to read `/root/rust/src/tools/rust-installer/Cargo.toml`
Caused by:
No such file or directory (os error 2)
Build completed unsuccessfully in 0:00:56
Then, running
git submodule update --init
./x.py build && sudo ./x.py dist --install
gives:
info: looks like you are running this command under `sudo`
and so in order to preserve your $HOME this will now
use vendored sources by default. Note that if this
does not work you should run a normal build first
before running a command like `sudo make install`
error: failed to load source for a dependency on `gcc`
Caused by:
Unable to update registry https://github.com/rust-lang/crates.io-index
Caused by:
failed to update replaced source `registry https://github.com/rust-lang/crates.io-index`
Caused by:
failed to read root of directory source: /root/rust/src/vendor
To learn more, run the command again with --verbose.
Build completed unsuccessfully in 0:00:00
/root/rust/src/vendor
doesn't exist
Activity
est31 commentedon May 16, 2017
Dupe of #40108
sylvestre commentedon May 16, 2017
the second part of my bug is a dupe, not the first one ( error: failed to read
/root/rust/src/tools/rust-installer/Cargo.toml
)cuviper commentedon May 16, 2017
Ugh -- I added rust-installer to the main workspace, but that means bootstrap can't build at all when the workspace is incomplete, so we never get the chance to automatically update submodules.
@alexcrichton any suggestions?
alexcrichton commentedon May 16, 2017
Bah this actually isn't the first time we've hit this bug, I should have caught this in review!
@cuviper I think the solution is to move the submodule logic to the python
x.py
script instead of rustbuild itself, and that's currently happening as part of #40291, but if it happens ahead of that I think that'd also be ok!cuviper commentedon May 16, 2017
You linked the #40291 issue twice -- is there a different number where the submodule logic is changing?
alexcrichton commentedon May 16, 2017
Oops sorry about that, the second link was intended to be #41639
alexcrichton commentedon May 20, 2017
#41639 has landed, so closing this