1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00
llvm-mirror/tools/llvm-objcopy/StripOpts.td
Alexander Shaposhnikov 936cf94651 [llvm-strip] Add missing aliases for --strip-debug
Add missing aliases for --strip-debug: -g, -S, -d.

Test plan: make check-all

Differential revision: https://reviews.llvm.org/D47674

llvm-svn: 333940
2018-06-04 18:55:41 +00:00

39 lines
1.0 KiB
TableGen

include "llvm/Option/OptParser.td"
multiclass Eq<string name> {
def NAME: Separate<["--", "-"], name>;
def NAME # _eq: Joined<["--", "-"], name # "=">, Alias<!cast<Separate>(NAME)>;
}
def help : Flag<["-", "--"], "help">;
defm output : Eq<"o">,
MetaVarName<"output">,
HelpText<"Write output to <file>">;
def strip_debug : Flag<["-", "--"], "strip-debug">,
HelpText<"Remove debugging symbols only">;
def d : Flag<["-"], "d">,
Alias<strip_debug>;
def g : Flag<["-"], "g">,
Alias<strip_debug>;
def S : Flag<["-"], "S">,
Alias<strip_debug>;
defm remove_section : Eq<"remove-section">,
MetaVarName<"section">,
HelpText<"Remove <section>">;
def R : JoinedOrSeparate<["-"], "R">,
Alias<remove_section>;
defm keep_symbol : Eq<"keep-symbol">,
MetaVarName<"symbol">,
HelpText<"Do not remove symbol <symbol>">;
def K : JoinedOrSeparate<["-"], "K">,
Alias<keep_symbol>;