Skip to content

Commit b001cae

Browse files
committed
Auto merge of #126278 - lqd:beta, r=<try>
[beta] Ensure self-contained linker is only enabled on dev/nightly It seems the self-contained linker is enabled on beta. Let's fix that. ```console $ cargo clean && cargo +beta build && readelf -p .comment target/debug/helloworld Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.15s String dump of section '.comment': [ 0] Linker: LLD 18.1.7 [ 14] GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0 [ 3f] rustc version 1.80.0-beta.1 (75ac3b6 2024-06-10) ``` I will open a PR to fix it on master as well, right after I test CI's behavior on beta.
2 parents 75ac3b6 + 50cb2ef commit b001cae

File tree

2 files changed

+4
-5
lines changed
  • library/alloc/src/collections/binary_heap
  • src/bootstrap/src/core/build_steps

2 files changed

+4
-5
lines changed

library/alloc/src/collections/binary_heap/mod.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -440,10 +440,7 @@ impl<T: Ord> BinaryHeap<T> {
440440
/// heap.push(4);
441441
/// ```
442442
#[stable(feature = "rust1", since = "1.0.0")]
443-
#[rustc_const_stable(
444-
feature = "const_binary_heap_constructor",
445-
since = "1.80.0"
446-
)]
443+
#[rustc_const_stable(feature = "const_binary_heap_constructor", since = "1.80.0")]
447444
#[must_use]
448445
pub const fn new() -> BinaryHeap<T> {
449446
BinaryHeap { data: vec![] }

src/bootstrap/src/core/build_steps/compile.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1137,7 +1137,9 @@ pub fn rustc_cargo_env(
11371137
}
11381138

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

0 commit comments

Comments
 (0)