[Bug 277333] Mk/Features/lto.mk: passing -C lto=no breaks LTO_UNSAFE ports
Date: Tue, 26 Mar 2024 18:45:56 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=277333 --- Comment #18 from Jan Beich <jbeich@FreeBSD.org> --- (In reply to Gleb Popov from comment #16) USES=cargo is not supposed to desync cargo vs. rustc, leading to an undefined behavior. If a Rust feature is exposed via Cargo then use Cargo variables to control it. Passing -C lto=no leads to some files built with LTO and some without LTO, likely causing rustc to leak LLVM bitcode (skipping optimization step) to the system linker (LTO-unaware or incompatible LLVM version). See also review D29548 which tried to move rustc bits into a separate USES. -- You are receiving this mail because: You are on the CC list for the bug.