Skip to content

Rustc cann't be build if stage0 compiler built with custom libdir #72661

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
o01eg opened this issue May 27, 2020 · 5 comments · Fixed by #72728
Closed

Rustc cann't be build if stage0 compiler built with custom libdir #72661

o01eg opened this issue May 27, 2020 · 5 comments · Fixed by #72728
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@o01eg
Copy link
Contributor

o01eg commented May 27, 2020

Stage0 compiler is the same 1.43.1 compiler but with libdir set to lib/rust-1.43.1.

Build log: build-fail.log.gz

Build fails on cfg-if crate while it was successfully built before llvm:

Successfull:

   Compiling cfg-if v0.1.10
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name cfg_if --edition=2018 /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 --cfg 'feature="compiler_builtins"' --cfg 'feature="core"' --cfg 'feature="rustc-dep-of-std"' -C metadata=ea138eb22fe07b6e -C extra-filename=-ea138eb22fe07b6e --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps --extern compiler_builtins=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta --extern core=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta --cap-lints allow -Zmacro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Cprefer-dynamic -Zbinary-dep-depinfo -L native=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/build/compiler_builtins-6a53cdec3946c317/out`
rustc command: "LD_LIBRARY_PATH"="/usr/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps:/usr/lib" "/usr/bin/rustc" "--crate-name" "cfg_if" "--edition=2018" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "--cfg" "feature=\"compiler_builtins\"" "--cfg" "feature=\"core\"" "--cfg" "feature=\"rustc-dep-of-std\"" "-C" "metadata=ea138eb22fe07b6e" "-C" "extra-filename=-ea138eb22fe07b6e" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps" "--extern" "compiler_builtins=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta" "--extern" "core=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta" "--cap-lints" "allow" "-Zmacro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "-L" "native=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/build/compiler_builtins-6a53cdec3946c317/out" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/usr/lib"

Failed:

   Compiling cfg-if v0.1.10
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name cfg_if --edition=2018 /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 -C metadata=42edf99289859e49 -C extra-filename=-42edf99289859e49 --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps --cap-lints allow -Zmacro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Zunstable-options '-Wrustc::internal' -Cprefer-dynamic -Zbinary-dep-depinfo`
rustc command: "LD_LIBRARY_PATH"="/usr/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps:/usr/lib" "/usr/bin/rustc" "--crate-name" "cfg_if" "--edition=2018" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "-C" "metadata=42edf99289859e49" "-C" "extra-filename=-42edf99289859e49" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps" "--cap-lints" "allow" "-Zmacro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Zunstable-options" "-Wrustc::internal" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/usr/lib"
error[E0463]: can't find crate for `core`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0463`.
error: could not compile `cfg-if`.

The first have dependencies set to in arguments --extern compiler_builtins=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta --extern core=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta.

@o01eg
Copy link
Contributor Author

o01eg commented May 27, 2020

With debug logs enabled:

   Compiling cfg-if v0.1.10
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name cfg_if --edition=2018 /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs --error-format=json --js
on=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 --cfg 'feature="compiler_builtins"' --cfg 'feature="core"' --cfg 'feature="rustc-dep-of-std"' -C metadata=ea138eb22fe07b6e 
-C extra-filename=-ea138eb22fe07b6e --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-li
nux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/
x86_64-unknown-linux-gnu/stage0-std/release/deps --extern compiler_builtins=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65
a289aa56fa5.rmeta --extern core=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta --cap-lints allow -
Zmacro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Cprefer-dynamic -Zbinary-dep-depinfo -L native=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/r
elease/build/compiler_builtins-6a53cdec3946c317/out`
rustc command: "LD_LIBRARY_PATH"="/usr/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps:/usr/lib" "/usr/bin/rustc" "--crate-name" "cfg_if" "--edition=2018" "/tmp/portage/de
v-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "--cfg" "featu
re=\"compiler_builtins\"" "--cfg" "feature=\"core\"" "--cfg" "feature=\"rustc-dep-of-std\"" "-C" "metadata=ea138eb22fe07b6e" "-C" "extra-filename=-ea138eb22fe07b6e" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/buil
d/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64
-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps" "--extern" "compiler_builtins=/tmp/porta
ge/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta" "--extern" "core=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.
1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta" "--cap-lints" "allow" "-Zmacro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-C
prefer-dynamic" "-Zbinary-dep-depinfo" "-L" "native=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/build/compiler_builtins-6a53cdec3946c317/out" "--sysroo
t" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/usr/lib"
[DEBUG rustc_metadata::creader] resolving extern crate stmt. ident: core orig_name: None
[INFO  rustc_metadata::creader] resolving crate `core`
[INFO  rustc_metadata::creader] falling back to a load
[DEBUG rustc_session::filesearch] using sysroot = /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot, triple = x86_64-unknown-linux-gnu
[INFO  rustc_metadata::locator] rmeta reading metadata from: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dc
e3d.rmeta
[INFO  rustc_metadata::locator] reading "librustc_std_workspace_core-4f06cf76701dce3d.rmeta" => 38.059µs
[INFO  rustc_metadata::creader] register crate `rustc_std_workspace_core` (private_dep = false)
[DEBUG rustc_metadata::creader] resolving deps of external crate
[INFO  rustc_metadata::creader] resolving dep crate core hash: `f5195a85aae464c4` extra filename: `-4538f57aeeff3159`
[INFO  rustc_metadata::creader] resolving crate `core`
[INFO  rustc_metadata::creader] falling back to a load
[DEBUG rustc_session::filesearch] using sysroot = /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot, triple = x86_64-unknown-linux-gnu
[DEBUG rustc_session::filesearch] searching /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rlib
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/liblibc-1424704ea4a5e235.rlib
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/liblibc-1424704ea4a5e235.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rlib
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rlib
[INFO  rustc_metadata::locator] lib candidate: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rlib
[DEBUG rustc_session::filesearch] picked /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcompiler_builtins-70d65a289aa56fa5.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/compiler_builtins-70d65a289aa56fa5.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/compiler_builtins-70d65a289aa56fa5.d
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/liblibc-1424704ea4a5e235.rmeta
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/liblibc-1424704ea4a5e235.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libc-1424704ea4a5e235.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libc-1424704ea4a5e235.d
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/librustc_std_workspace_core-4f06cf76701dce3d.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/rustc_std_workspace_core-4f06cf76701dce3d.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/rustc_std_workspace_core-4f06cf76701dce3d.d
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rmeta
[INFO  rustc_metadata::locator] lib candidate: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rmeta
[DEBUG rustc_session::filesearch] picked /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/core-4538f57aeeff3159.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/core-4538f57aeeff3159.d
[DEBUG rustc_session::filesearch] searching /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libautocfg-4ad8357f85f13c71.rlib
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libautocfg-4ad8357f85f13c71.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libcc-0cbd7187a850fe6e.rlib
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libcc-0cbd7187a850fe6e.rlib
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libautocfg-4ad8357f85f13c71.rmeta
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libautocfg-4ad8357f85f13c71.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/autocfg-4ad8357f85f13c71.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/autocfg-4ad8357f85f13c71.d
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libcc-0cbd7187a850fe6e.rmeta
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/libcc-0cbd7187a850fe6e.rmeta
[DEBUG rustc_session::filesearch] testing /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/cc-0cbd7187a850fe6e.d
[DEBUG rustc_session::filesearch] rejected /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps/cc-0cbd7187a850fe6e.d
[DEBUG rustc_session::filesearch] searching /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rust-1.43.1/rustlib/x86_64-unknown-linux-gnu/lib
[INFO  rustc_metadata::locator] rmeta reading metadata from: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps/libcore-4538f57aeeff3159.rmeta
[INFO  rustc_metadata::locator] reading "libcore-4538f57aeeff3159.rmeta" => 56.401µs
[INFO  rustc_metadata::creader] register crate `core` (private_dep = false)
[DEBUG rustc_metadata::creader] resolving deps of external crate

Failed:

   Compiling cfg-if v0.1.10
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name cfg_if --edition=2018 /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 -C metadata=42edf99289859e49 -C extra-filename=-42edf99289859e49 --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps --cap-lints allow -Zmacro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Zunstable-options '-Wrustc::internal' -Cprefer-dynamic -Zbinary-dep-depinfo`
rustc command: "LD_LIBRARY_PATH"="/usr/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps:/usr/lib" "/usr/bin/rustc" "--crate-name" "cfg_if" "--edition=2018" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "-C" "metadata=42edf99289859e49" "-C" "extra-filename=-42edf99289859e49" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps" "--cap-lints" "allow" "-Zmacro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Zunstable-options" "-Wrustc::internal" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/usr/lib"
[DEBUG rustc_metadata::creader] resolving extern crate stmt. ident: core orig_name: None
[INFO  rustc_metadata::creader] resolving crate `core`
[INFO  rustc_metadata::creader] falling back to a load
[DEBUG rustc_session::filesearch] using sysroot = /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot, triple = x86_64-unknown-linux-gnu
[DEBUG rustc_session::filesearch] searching /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rust-1.43.1/rustlib/x86_64-unknown-linux-gnu/lib
[DEBUG rustc_session::filesearch] using sysroot = /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot, triple = x86_64-unknown-linux-gnu
[DEBUG rustc_session::filesearch] searching /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rust-1.43.1/rustlib/x86_64-unknown-linux-gnu/lib

@o01eg
Copy link
Contributor Author

o01eg commented May 28, 2020

When I use pre-built stage0 compiler:

   Compiling cfg-if v0.1.10
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name cfg_if --edition=2018 /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 -C metadata=839ba1f5688689c8 -C extra-filename=-839ba1f5688689c8 --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps --cap-lints allow --cfg=bootstrap -Zexternal-macro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Zunstable-options '-Wrustc::internal' -Cprefer-dynamic -Zbinary-dep-depinfo`
rustc command: "LD_LIBRARY_PATH"="/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps:/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib" "/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/bin/rustc" "--crate-name" "cfg_if" "--edition=2018" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/vendor/cfg-if/src/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "-C" "metadata=839ba1f5688689c8" "-C" "extra-filename=-839ba1f5688689c8" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps" "--cap-lints" "allow" "--cfg=bootstrap" "-Zexternal-macro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Zunstable-options" "-Wrustc::internal" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib"
[INFO  rustc_metadata::creader] resolving crate `core`
[INFO  rustc_metadata::creader] falling back to a load
[INFO  rustc_metadata::locator] lib candidate: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-17765580c343294b.rlib
[INFO  rustc_metadata::locator] rlib reading metadata from: /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-17765580c343294b.rlib
[INFO  rustc_metadata::locator] reading "libcore-17765580c343294b.rlib" => 63.478µs
[INFO  rustc_metadata::creader] register crate `core` (private_dep = false)

@o01eg
Copy link
Contributor Author

o01eg commented May 28, 2020

This core was build at:

   Compiling core v0.0.0 (/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/src/libcore)
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name core --edition=2018 src/libcore/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 -C metadata=17765580c343294b -C extra-filename=-17765580c343294b --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps --cfg=bootstrap -Zexternal-macro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Cprefer-dynamic -Zbinary-dep-depinfo`
rustc command: "LD_LIBRARY_PATH"="/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps:/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib" "/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/bin/rustc" "--crate-name" "core" "--edition=2018" "src/libcore/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "-C" "metadata=17765580c343294b" "-C" "extra-filename=-17765580c343294b" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps" "--cfg=bootstrap" "-Zexternal-macro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/tmp/portage/dev-lang/rust-1.43.1/work/rust-stage0/lib"
[INFO  rustc_metadata::creader] panic runtime injection skipped, only generating rlib
[INFO  rustc_metadata::creader] resolved crates:

With system compiler 1.43.1 same is:

   Compiling core v0.0.0 (/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/src/libcore)
     Running `/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/bootstrap/debug/rustc --crate-name core --edition=2018 src/libcore/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C debuginfo=0 -C metadata=4538f57aeeff3159 -C extra-filename=-4538f57aeeff3159 --out-dir /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps --target x86_64-unknown-linux-gnu -C linker=x86_64-pc-linux-gnu-gcc -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps -L dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps -Zmacro-backtrace -Wrust_2018_idioms -Wunused_lifetimes -Dwarnings -Cprefer-dynamic -Zbinary-dep-depinfo`
rustc command: "LD_LIBRARY_PATH"="/usr/lib:/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps:/usr/lib" "/usr/bin/rustc" "--crate-name" "core" "--edition=2018" "src/libcore/lib.rs" "--error-format=json" "--json=diagnostic-rendered-ansi,artifacts" "--crate-type" "lib" "--emit=dep-info,metadata,link" "-C" "opt-level=3" "-C" "debuginfo=0" "-C" "metadata=4538f57aeeff3159" "-C" "extra-filename=-4538f57aeeff3159" "--out-dir" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "--target" "x86_64-unknown-linux-gnu" "-C" "linker=x86_64-pc-linux-gnu-gcc" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/x86_64-unknown-linux-gnu/release/deps" "-L" "dependency=/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-std/release/deps" "-Zmacro-backtrace" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Dwarnings" "-Cprefer-dynamic" "-Zbinary-dep-depinfo" "--sysroot" "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot" "-C" "debug-assertions=n" "-Z" "force-unstable-if-unmarked"
sysroot: "/tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot"
libdir: "/usr/lib"
[INFO  rustc_metadata::creader] panic runtime injection skipped, only generating rlib
[INFO  rustc_metadata::creader] resolved crates:
[DEBUG rustc_session::filesearch] using sysroot = /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot, triple = x86_64-unknown-linux-gnu

@o01eg
Copy link
Contributor Author

o01eg commented May 28, 2020

I suppose compiler awaits library in /tmp/portage/dev-lang/rust-1.43.1/work/rustc-1.43.1-src/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rust-1.43.1/rustlib/x86_64-unknown-linux-gnu/lib/libcore-17765580c343294b.rlib and it depends on version of bootstrap compiler.

  1. Should compiler set libdir to default value if sysroot was changed?
  2. Or maybe add argument to set target-libdir like it done with sysroot?
  3. Maybe query libdir from stage0 compiler and use it to place libraries correctly?

@o01eg
Copy link
Contributor Author

o01eg commented May 28, 2020

/// Returns the compiler's relative libdir where the standard library and other artifacts are
/// found for a compiler's sysroot.
///
/// For example this returns `lib` on Unix and Windows.
pub fn sysroot_libdir_relative(&self, compiler: Compiler) -> &Path {
match self.config.libdir_relative() {
Some(relative_libdir) if compiler.stage >= 1 => relative_libdir,
_ => Path::new("lib"),
}
}

While stage0 compiler can have custom libdir this function returns lib.

@LeSeulArtichaut LeSeulArtichaut added T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 29, 2020
RalfJung added a commit to RalfJung/rust that referenced this issue May 30, 2020
Make bootstrap aware of relative libdir in stage0 compiler

Follows up rust-lang#72692

Fixes rust-lang#72661
@bors bors closed this as completed in 8f1c0d0 May 31, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants