From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 8B6361581EE for ; Fri, 21 Mar 2025 19:14:18 +0000 (UTC) Received: from lists.gentoo.org (bobolink.gentoo.org [140.211.166.189]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id 7994E34323F for ; Fri, 21 Mar 2025 19:14:18 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id 704E91104AB; Fri, 21 Mar 2025 19:14:17 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bobolink.gentoo.org (Postfix) with ESMTPS id 643531104AB for ; Fri, 21 Mar 2025 19:14:17 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0D86F343162 for ; Fri, 21 Mar 2025 19:14:17 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 697271C96 for ; Fri, 21 Mar 2025 19:14:15 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1742584375.caea6d9760e3f9a67d6e9205ae6c176548b19927.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/rust/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-lang/rust/rust-1.84.0-r1.ebuild dev-lang/rust/rust-1.84.1-r1.ebuild dev-lang/rust/rust-1.85.0-r1.ebuild dev-lang/rust/rust-1.85.0.ebuild dev-lang/rust/rust-1.85.1.ebuild dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild dev-lang/rust/rust-1.86.0_beta20250225.ebuild dev-lang/rust/rust-9999.ebuild X-VCS-Directories: dev-lang/rust/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: caea6d9760e3f9a67d6e9205ae6c176548b19927 X-VCS-Branch: master Date: Fri, 21 Mar 2025 19:14:15 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: e68f6136-4c55-466e-b895-74aac14a7011 X-Archives-Hash: c959d0cea5854ce69642f47bd9118bbe commit: caea6d9760e3f9a67d6e9205ae6c176548b19927 Author: Z. Liu gmail com> AuthorDate: Wed Feb 26 15:18:52 2025 +0000 Commit: Sam James gentoo org> CommitDate: Fri Mar 21 19:12:55 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=caea6d97 dev-lang/rust: fix build using clang but not lld use-lld appeared first in commit bfba6ef328bbba327cae8918e795c11b89217672 refactored in commit befd1eb4ec78e19f0c8628fa75241ea3ed6ec792 Closes: https://bugs.gentoo.org/948027 Signed-off-by: Z. Liu gmail.com> Closes: https://github.com/gentoo/gentoo/pull/40772 Signed-off-by: Sam James gentoo.org> dev-lang/rust/rust-1.84.0-r1.ebuild | 8 ++++++++ dev-lang/rust/rust-1.84.1-r1.ebuild | 8 ++++++++ dev-lang/rust/rust-1.85.0-r1.ebuild | 8 ++++++++ dev-lang/rust/rust-1.85.0.ebuild | 8 ++++++++ dev-lang/rust/rust-1.85.1.ebuild | 8 ++++++++ dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild | 8 ++++++++ dev-lang/rust/rust-1.86.0_beta20250225.ebuild | 8 ++++++++ dev-lang/rust/rust-9999.ebuild | 8 ++++++++ 8 files changed, 64 insertions(+) diff --git a/dev-lang/rust/rust-1.84.0-r1.ebuild b/dev-lang/rust/rust-1.84.0-r1.ebuild index 6fc4e46d7241..83b5a9c1a3dd 100644 --- a/dev-lang/rust/rust-1.84.0-r1.ebuild +++ b/dev-lang/rust/rust-1.84.0-r1.ebuild @@ -68,6 +68,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -234,6 +235,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -386,6 +391,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.84.1-r1.ebuild b/dev-lang/rust/rust-1.84.1-r1.ebuild index 4dd53ebc8d05..b6f28c029fd4 100644 --- a/dev-lang/rust/rust-1.84.1-r1.ebuild +++ b/dev-lang/rust/rust-1.84.1-r1.ebuild @@ -68,6 +68,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -234,6 +235,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -386,6 +391,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.85.0-r1.ebuild b/dev-lang/rust/rust-1.85.0-r1.ebuild index 011b8572a939..9bfbad9c8626 100644 --- a/dev-lang/rust/rust-1.85.0-r1.ebuild +++ b/dev-lang/rust/rust-1.85.0-r1.ebuild @@ -94,6 +94,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -306,6 +307,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -473,6 +478,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.85.0.ebuild b/dev-lang/rust/rust-1.85.0.ebuild index e7079ae7c11e..88b742cc5112 100644 --- a/dev-lang/rust/rust-1.85.0.ebuild +++ b/dev-lang/rust/rust-1.85.0.ebuild @@ -94,6 +94,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -305,6 +306,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -472,6 +477,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.85.1.ebuild b/dev-lang/rust/rust-1.85.1.ebuild index 011b8572a939..9bfbad9c8626 100644 --- a/dev-lang/rust/rust-1.85.1.ebuild +++ b/dev-lang/rust/rust-1.85.1.ebuild @@ -94,6 +94,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -306,6 +307,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -473,6 +478,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild b/dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild index bbf7e2c95c8c..c22abb3204b7 100644 --- a/dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild +++ b/dev-lang/rust/rust-1.86.0_beta20250218-r1.ebuild @@ -95,6 +95,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -313,6 +314,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -480,6 +485,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-1.86.0_beta20250225.ebuild b/dev-lang/rust/rust-1.86.0_beta20250225.ebuild index 7ccdcd48b3d6..7590d615f095 100644 --- a/dev-lang/rust/rust-1.86.0_beta20250225.ebuild +++ b/dev-lang/rust/rust-1.86.0_beta20250225.ebuild @@ -95,6 +95,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -313,6 +314,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -480,6 +485,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526 diff --git a/dev-lang/rust/rust-9999.ebuild b/dev-lang/rust/rust-9999.ebuild index d7dd9d8d660c..72e640905646 100644 --- a/dev-lang/rust/rust-9999.ebuild +++ b/dev-lang/rust/rust-9999.ebuild @@ -94,6 +94,7 @@ BDEPEND="${PYTHON_DEPS} >=sys-devel/gcc-4.7[cxx] >=llvm-core/clang-3.5 ) + lto? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') ) !system-llvm? ( >=dev-build/cmake-3.13.4 app-alternatives/ninja @@ -306,6 +307,10 @@ src_prepare() { fi fi + if use lto && tc-is-clang && ! tc-ld-is-lld; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + default } @@ -474,6 +479,9 @@ src_configure() { dist-src = false remap-debuginfo = true lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang ; then + echo "use-lld = true" + fi) # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it # https://github.com/rust-lang/rust/issues/74976 # https://github.com/rust-lang/rust/issues/76526