Skip to content

Commit

Permalink
Rollup merge of rust-lang#126282 - lqd:contain-the-self-contained-lin…
Browse files Browse the repository at this point in the history
…ker, r=Mark-Simulacrum

Ensure self-contained linker is only enabled on dev/nightly

This is a version of rust-lang#126278 for the master branch. It should be no-op _here_, compared to beta.

I'll r? `@Mark-Simulacrum` like the other one.
  • Loading branch information
compiler-errors authored Jun 12, 2024
2 parents 3065010 + bbc5037 commit 49b28a4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/bootstrap/src/core/build_steps/compile.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1137,7 +1137,9 @@ pub fn rustc_cargo_env(
}

// Enable rustc's env var for `rust-lld` when requested.
if builder.config.lld_enabled {
if builder.config.lld_enabled
&& (builder.config.channel == "dev" || builder.config.channel == "nightly")
{
cargo.env("CFG_USE_SELF_CONTAINED_LINKER", "1");
}

Expand Down

0 comments on commit 49b28a4

Please sign in to comment.