You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Xargo fails to build the rust source due to it incorrectly getting a reference to the lockfile for the rust-lib.
Currently, we get the lockfile reference through the following code in sysroot.rs:118:
// rust-src comes with a lockfile for libstd. Use it.let src_parent = src.path().parent().map(Path::to_path_buf).unwrap_or_else(|| src.path().join(".."));let lockfile = src_parent.join("Cargo.lock");
From debugging, src_parent points to toolchain-path/lib/rustlib/src/rust/ and not the actual directory where we can find the correct lockfile for rust-lib, which would be: toolchain-path/lib/rustlib/src/rust/library/. Maybe this is just unique to my system. I remember this working a while ago. I have solved this locally by doing something like this:
let lockfile = src.path().join("Cargo.lock");
and fully circumventing the src_parent, since it's not needed anywhere else.
The text was updated successfully, but these errors were encountered:
Xargo fails to build the rust source due to it incorrectly getting a reference to the lockfile for the rust-lib.
Currently, we get the lockfile reference through the following code in
sysroot.rs:118
:From debugging,
src_parent
points totoolchain-path/lib/rustlib/src/rust/
and not the actual directory where we can find the correct lockfile for rust-lib, which would be:toolchain-path/lib/rustlib/src/rust/library/
. Maybe this is just unique to my system. I remember this working a while ago. I have solved this locally by doing something like this:and fully circumventing the
src_parent
, since it's not needed anywhere else.The text was updated successfully, but these errors were encountered: