git: 3df88d665d28 - main - devel/electron34: fix build with rust 1.89.0

From: Hiroki Tagato <tagattie_at_FreeBSD.org>
Date: Tue, 26 Aug 2025 22:59:55 UTC
The branch main has been updated by tagattie:

URL: https://cgit.FreeBSD.org/ports/commit/?id=3df88d665d2854f49ea0b487790d9b54f81077f6

commit 3df88d665d2854f49ea0b487790d9b54f81077f6
Author:     Mikael Urankar <mikael@FreeBSD.org>
AuthorDate: 2025-08-26 22:58:27 +0000
Commit:     Hiroki Tagato <tagattie@FreeBSD.org>
CommitDate: 2025-08-26 22:59:36 +0000

    devel/electron34: fix build with rust 1.89.0
    
    Obtained from:  https://chromium.googlesource.com/chromium/src/+/6aae0e2353c857d98980ff677bf304288d7c58de
    Pull Request:   https://github.com/tagattie/FreeBSD-Electron/pull/165
---
 devel/electron34/files/patch-build_rust_allocator_lib.rs | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/devel/electron34/files/patch-build_rust_allocator_lib.rs b/devel/electron34/files/patch-build_rust_allocator_lib.rs
index 89fddf278294..3e1dd7dcb48b 100644
--- a/devel/electron34/files/patch-build_rust_allocator_lib.rs
+++ b/devel/electron34/files/patch-build_rust_allocator_lib.rs
@@ -1,6 +1,6 @@
---- build/rust/allocator/lib.rs.orig	2025-05-20 09:16:26 UTC
+--- build/rust/allocator/lib.rs.orig	2025-08-26 22:47:37 UTC
 +++ build/rust/allocator/lib.rs
-@@ -0,0 +1,119 @@
+@@ -0,0 +1,125 @@
 +// Copyright 2025 The Chromium Authors
 +// Use of this source code is governed by a BSD-style license that can be
 +// found in the LICENSE file.
@@ -92,6 +92,12 @@
 +    /// As part of rustc's contract for using `#[global_allocator]` without
 +    /// rustc-generated shims we must define this symbol, since we are opting in
 +    /// to unstable functionality. See https://github.com/rust-lang/rust/issues/123015
++    #[rustc_std_internal_symbol]
++    #[linkage = "weak"]
++    fn __rust_no_alloc_shim_is_unstable_v2() {}
++
++    // TODO(crbug.com/422538133) Remove after rolling past
++    // https://github.com/rust-lang/rust/pull/141061
 +    #[no_mangle]
 +    #[linkage = "weak"]
 +    static __rust_no_alloc_shim_is_unstable: u8 = 0;