From 6dbead14025afb8b8b14f343e5d939bd26a3d0ab Mon Sep 17 00:00:00 2001 From: robertsLando Date: Fri, 10 Apr 2026 11:02:38 +0200 Subject: [PATCH] build: remove redundant -fuse-linker-plugin from GCC LTO flags The `-fuse-linker-plugin` flag has been automatically enabled by GCC since version 5 when LTO is active, making the explicit flag redundant. Since Node.js requires GCC >= 13.2, this flag serves no purpose. Removing it also improves portability with alternative linkers (mold, lld) that may not support GCC's linker plugin interface, avoiding build failures when these linkers are used with GCC LTO builds. Refs: https://github.com/yao-pkg/pkg/issues/231 Signed-off-by: Daniel Lando --- common.gypi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common.gypi b/common.gypi index 953a1448d4baa5..183d8707682e8e 100644 --- a/common.gypi +++ b/common.gypi @@ -189,7 +189,7 @@ ['clang==1', { 'lto': ' -flto ', # Clang }, { - 'lto': ' -flto=4 -fuse-linker-plugin -ffat-lto-objects ', # GCC + 'lto': ' -flto=4 -ffat-lto-objects ', # GCC }], ], },