[lld] 06a0dd2 - [lld-macho] Ignore -dependency_info and its argument

Jez Ng via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 24 16:16:31 PDT 2020


Author: Jez Ng
Date: 2020-07-24T15:55:27-07:00
New Revision: 06a0dd2467d5c4726699eea3589a6444e00a2eef

URL: https://github.com/llvm/llvm-project/commit/06a0dd2467d5c4726699eea3589a6444e00a2eef
DIFF: https://github.com/llvm/llvm-project/commit/06a0dd2467d5c4726699eea3589a6444e00a2eef.diff

LOG: [lld-macho] Ignore -dependency_info and its argument

XCode passes in this flag, which we do not yet implement. Skip
over the argument for now so we can at least successfully parse the
linker invocation.

Reviewed By: #lld-macho, compnerd

Differential Revision: https://reviews.llvm.org/D84485

Added: 
    

Modified: 
    lld/MachO/Options.td
    lld/test/MachO/silent-ignore.test

Removed: 
    


################################################################################
diff  --git a/lld/MachO/Options.td b/lld/MachO/Options.td
index 1e42542b9ac4..7d81ca7c1427 100644
--- a/lld/MachO/Options.td
+++ b/lld/MachO/Options.td
@@ -456,6 +456,11 @@ def map : Separate<["-"], "map">,
      HelpText<"Writes all symbols and their addresses to <path>">,
      Flags<[HelpHidden]>,
      Group<grp_introspect>;
+def dependency_info : Separate<["-"], "dependency_info">,
+     MetaVarName<"<path>">,
+     HelpText<"Dump dependency info">,
+     Flags<[HelpHidden]>,
+     Group<grp_introspect>;
 
 def grp_symtab : OptionGroup<"symtab">, HelpText<"SYMBOL TABLE OPTIMIZATIONS">;
 
@@ -1098,10 +1103,6 @@ def demangle : Flag<["-"], "demangle">,
      HelpText<"This option is undocumented in ld64">,
      Flags<[HelpHidden]>,
      Group<grp_undocumented>;
-def dependency_info : Flag<["-"], "dependency_info">,
-     HelpText<"This option is undocumented in ld64">,
-     Flags<[HelpHidden]>,
-     Group<grp_undocumented>;
 def dyld_env : Flag<["-"], "dyld_env">,
      HelpText<"This option is undocumented in ld64">,
      Flags<[HelpHidden]>,

diff  --git a/lld/test/MachO/silent-ignore.test b/lld/test/MachO/silent-ignore.test
index ae68dd8fe81f..0d2086386fa8 100644
--- a/lld/test/MachO/silent-ignore.test
+++ b/lld/test/MachO/silent-ignore.test
@@ -4,6 +4,7 @@ RUN:   -dynamic \
 RUN:   -no_deduplicate \
 RUN:   -lto_library /lib/foo \
 RUN:   -macosx_version_min 0 \
+RUN:   -dependency_info /path/to/dependency_info.dat \
 RUN:   -syslibroot /path/to/MacOSX.platform/Developer/SDKs/MacOSX.sdk
 RUN: not lld -flavor darwinnew -v --not-an-ignored-argument 2>&1 | FileCheck %s
 CHECK: error: unknown argument: --not-an-ignored-argument


        


More information about the llvm-commits mailing list