1 // Include the common option parsing interfaces.
2 include "llvm/Option/OptParser.td"
4 class FF<string name, string help>: Flag<["-", "--"], name>, HelpText<help>;
5 multiclass JS<string name, string help, string var = ""> {
6 def NAME #_EQ : Joined<["--"], name #"=">, HelpText<help>, MetaVarName<var>;
7 def : Separate<["-", "--"], name>, Alias<!cast<Joined>(NAME #_EQ)>;
11 // Top level operations
13 def action_group : OptionGroup<"action group">, HelpText<"COMMANDS">;
14 def compare : FF<"compare", "compare tapi files for library differences">, Group<action_group>;
15 def merge : FF<"merge", "merge the input files that represent the same library">, Group<action_group>;
16 def extract: FF<"extract", "extract <architecture> from input file">, Group<action_group>;
17 def remove: FF<"remove", "remove <architecture> from input file">, Group<action_group>;
18 def stubify: FF<"stubify", "create a tapi file from a dynamic library or framework">, Group<action_group>;
21 // General Driver options
23 def help : FF<"help", "display this help">;
24 def version: FF<"version", "print the llvm-readtapi version">;
25 def v: FF<"v", "alias for --version">, Alias<version>;
26 defm output: JS<"o", "write output to <file>","<file>">;
27 def compact: FF<"compact", "write compact tapi output file">;
28 defm filetype: JS<"filetype", "specify the output file type (tbd-v3, tbd-v4 or tbd-v5)","<value>">;
29 defm arch: JS<"arch", "specify the <architecture>", "<architecture>">;
34 def delete_input : FF<"delete-input", "delete and replace input file on success">;
35 def delete_private_libraries : FF<"delete-private-libraries", "delete private system dynamic libraries and frameworks">;
36 def t: FF<"t", "logs each library loaded, useful for debugging problems with search paths where the wrong library is loaded">;
42 defm ignore_arch : JS<"ignore-arch", "<architecture> slice to ignore for comparison", "<architecture>">;