From nobody Wed Apr 1 22:11:52 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3FACE3FB7FA; Wed, 1 Apr 2026 11:47:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775044070; cv=none; b=sFFWUAF7BJLIobcne8p0MvEL4cRzN31UDZ3zck4aDuUn27Btoh5VL19MYh8e81V7WMpTuIPnrBeo2mW6GcKhqjYxPboS4YibVixj/KJVQk95TmJQszIheZJxBPfDLVyQYlqrxGy/jcfODyi9dXK6iccqKr5e/a1n+I3c8THvCYY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775044070; c=relaxed/simple; bh=xsU9IffmhOUWeURxd1cBn+xx+oWcdYdxyuUvVgPmku0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=c6o9KKC2CcZ3PhTyWIsjzpe3Y41onXsf70y6PioLlt2p96E7JyPT24cdHCzVFQ4U7+N+se68aN5xjTof5Q4eRpaXm/dwzplTN05tccnhifS1IZ0PnuKJJ6QVaUy3CN5llxjH/xvZkeqvBHtfAbINef/NMMJNVAAwP+Jet84gD/Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=bw0XQFM9; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="bw0XQFM9" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 98766C116C6; Wed, 1 Apr 2026 11:47:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1775044069; bh=xsU9IffmhOUWeURxd1cBn+xx+oWcdYdxyuUvVgPmku0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=bw0XQFM9BtXzltVVfX1cRyS5Ny7916Ny6Nrc3TLq9KJZYh0JtBh+ukTFEyx8Z85t8 /vt7Jbc/zq1y9bQ1shJhG3VR8TxOtBZF4NjJHMa7mU/xZAlefh37LD+NPTu+Ydfi49 JZ53a+OUpRjXBEozckaDoUhJgDDxIg+j6uv+ZggEvUq3It6rUqjdZ6bh+lQmBq+fnd qgyPYo7kcXdNsMmw1yjq21a8J89cwAmGQvzQVu5nFumVK/lfkLoYnqg7V/B3EDnv2S Uy6UH8O6mHui9UIcrilZWtiKbbK/WhNF71Bx912WmOVg7CuvV4vNq3M2vlDeu6Xlr9 RAOV3bDFHx0ZA== From: Miguel Ojeda To: Miguel Ojeda , Nathan Chancellor , Nicolas Schier , Danilo Krummrich , Andreas Hindborg , Catalin Marinas , Will Deacon , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Courbot , David Airlie , Simona Vetter , Brendan Higgins , David Gow , Greg Kroah-Hartman , =?UTF-8?q?Arve=20Hj=C3=B8nnev=C3=A5g?= , Todd Kjos , Christian Brauner , Carlos Llamas , Alice Ryhl , Jonathan Corbet Cc: Boqun Feng , Gary Guo , =?UTF-8?q?Bj=C3=B6rn=20Roy=20Baron?= , Benno Lossin , Trevor Gross , rust-for-linux@vger.kernel.org, linux-kbuild@vger.kernel.org, Lorenzo Stoakes , Vlastimil Babka , "Liam R . Howlett" , Uladzislau Rezki , linux-block@vger.kernel.org, linux-arm-kernel@lists.infradead.org (moderated for non-subscribers), Alexandre Ghiti , linux-riscv@lists.infradead.org, nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Rae Moar , linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com, Nick Desaulniers , Bill Wendling , Justin Stitt , llvm@lists.linux.dev, linux-kernel@vger.kernel.org, Shuah Khan , linux-doc@vger.kernel.org Subject: [PATCH 09/33] rust: kbuild: make `--remap-path-prefix` workaround conditional Date: Wed, 1 Apr 2026 13:45:16 +0200 Message-ID: <20260401114540.30108-10-ojeda@kernel.org> In-Reply-To: <20260401114540.30108-1-ojeda@kernel.org> References: <20260401114540.30108-1-ojeda@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The Internal Compiler Error that the comment mentions [1] was fixed in Rust 1.87.0 [2]. And, for other workarounds, we plan on limiting where we apply them [3]. Thus limit the ICE one too. This will help to make sure the workaround is not needed anymore on newer versions. Link: https://github.com/rust-lang/rust/issues/138520 [1] Link: https://github.com/rust-lang/rust/pull/138556 [2] Link: https://lore.kernel.org/rust-for-linux/20260205131815.2943152-2-mlksv= ender@gmail.com/ [3] Signed-off-by: Miguel Ojeda --- rust/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rust/Makefile b/rust/Makefile index 708530ee3613..163d2258e93f 100644 --- a/rust/Makefile +++ b/rust/Makefile @@ -145,10 +145,12 @@ doctests_modifiers_workaround :=3D $(rustdoc_modifier= s_workaround)$(if $(call rust # `rustdoc` ICEs on out-of-tree builds in Rust < 1.87.0 # (https://github.com/rust-lang/rust/issues/138520). Thus workaround the # issue skipping the flag. +rustdoc_remap_workaround :=3D $(if $(call rustc-min-version,108700),,--rem= ap-path-prefix=3D%) + quiet_cmd_rustdoc =3D RUSTDOC $(if $(rustdoc_host),H, ) $< cmd_rustdoc =3D \ OBJTREE=3D$(abspath $(objtree)) \ - $(RUSTDOC) $(filter-out $(skip_flags) --remap-path-prefix=3D%,$(if $(rust= doc_host),$(rust_common_flags),$(rust_flags))) \ + $(RUSTDOC) $(filter-out $(skip_flags) $(rustdoc_remap_workaround),$(if $(= rustdoc_host),$(rust_common_flags),$(rust_flags))) \ $(rustc_target_flags) -L$(objtree)/$(obj) \ -Zunstable-options --generate-link-to-definition \ --output $(rustdoc_output) \ --=20 2.53.0