Blame 0001-Add-back-ignored-option-no-add-needed.patch

6d38530
From 6511aedea2259bd09facc410f6b30eca8dc89b3d Mon Sep 17 00:00:00 2001
6d38530
From: Tom Stellard <tstellar@redhat.com>
6d38530
Date: Wed, 30 Mar 2022 21:26:09 -0700
6d38530
Subject: [PATCH] Add back ignored option --no-add-needed
6d38530
6d38530
This partially reverts commit 815a1207bfe121c8dcf3804a4f4638e580f63519.
6d38530
gcc 12.0.1 passes this option to the linker when compiling with -fuse-ld=lld.
6d38530
---
6d38530
 lld/ELF/Options.td              | 1 +
6d38530
 lld/test/ELF/silent-ignore.test | 1 +
6d38530
 2 files changed, 2 insertions(+)
6d38530
6d38530
diff --git a/lld/ELF/Options.td b/lld/ELF/Options.td
6d38530
index ca9fdcde791f..dedf5447d956 100644
6d38530
--- a/lld/ELF/Options.td
6d38530
+++ b/lld/ELF/Options.td
6d38530
@@ -695,6 +695,7 @@ def plugin_opt_eq : J<"plugin-opt=">;
6d38530
 def: F<"detect-odr-violations">;
6d38530
 def: Flag<["-"], "g">;
6d38530
 def: F<"long-plt">;
6d38530
+def: F<"no-add-needed">;
6d38530
 def: F<"no-copy-dt-needed-entries">;
6d38530
 def: F<"no-ctors-in-init-array">;
6d38530
 def: F<"no-keep-memory">;
6d38530
diff --git a/lld/test/ELF/silent-ignore.test b/lld/test/ELF/silent-ignore.test
6d38530
index 91b57434765f..2a4bf02ad95f 100644
6d38530
--- a/lld/test/ELF/silent-ignore.test
6d38530
+++ b/lld/test/ELF/silent-ignore.test
6d38530
@@ -2,6 +2,7 @@ RUN: ld.lld --version \
6d38530
 RUN:   -detect-odr-violations \
6d38530
 RUN:   -g \
6d38530
 RUN:   -long-plt \
6d38530
+RUN:   -no-add-needed \
6d38530
 RUN:   -no-copy-dt-needed-entries \
6d38530
 RUN:   -no-ctors-in-init-array \
6d38530
 RUN:   -no-keep-memory \
6d38530
-- 
6d38530
2.27.0
6d38530