mirror of
https://github.com/rui314/mold.git
synced 2024-11-11 16:58:12 +03:00
66 lines
2.0 KiB
TableGen
66 lines
2.0 KiB
TableGen
include "llvm/Option/OptParser.td"
|
|
|
|
class F<string name>: Flag<["--", "-"], name>;
|
|
class J<string name>: Joined<["--", "-"], name>;
|
|
|
|
multiclass Eq<string name, string help> {
|
|
def NAME: Separate<["--", "-"], name>;
|
|
def NAME # _eq: Joined<["--", "-"], name # "=">, Alias<!cast<Separate>(NAME)>,
|
|
HelpText<help>;
|
|
}
|
|
|
|
def o: JoinedOrSeparate<["-"], "o">, MetaVarName<"<path>">,
|
|
HelpText<"Path to file to write output">;
|
|
|
|
def print_map: F<"print-map">,
|
|
HelpText<"Print a link map to the standard output">;
|
|
|
|
defm thread_count: Eq<"thread-count", "Number of threads to use">;
|
|
|
|
def stat: F<"stat">;
|
|
|
|
def static: F<"static">, HelpText<"Do not link against shared libraries">;
|
|
|
|
defm trace_symbol: Eq<"trace-symbol", "Trace references to symbol">;
|
|
|
|
def trace: F<"trace">, HelpText<"Print the name of each input file">;
|
|
|
|
def filler: Separate<["--", "-"], "filler">;
|
|
|
|
defm library: Eq<"library", "Root name of library to use">,
|
|
MetaVarName<"<libName>">;
|
|
|
|
defm library_path: Eq<"library-path", "Add a directory to the library search path">,
|
|
MetaVarName<"<dir>">;
|
|
|
|
defm sysroot: Eq<"sysroot", "Set the system root">;
|
|
|
|
defm dynamic_linker: Eq<"dynamic-linker", "Which dynamic linker to use">;
|
|
|
|
def: JoinedOrSeparate<["-"], "l">, Alias<library>, HelpText<"Alias for --library">;
|
|
def: JoinedOrSeparate<["-"], "L">, Alias<library_path>, HelpText<"Alias for --library-path">;
|
|
def: JoinedOrSeparate<["-"], "y">, Alias<trace_symbol>, HelpText<"Alias for --trace-symbol">;
|
|
|
|
def as_needed: F<"as-needed">;
|
|
def no_as_needed: F<"no-as-needed">;
|
|
|
|
defm rpath: Eq<"rpath", "Add a DT_RUNPATH to the output">;
|
|
|
|
def export_dynamic: F<"export-dynamic">,
|
|
HelpText<"Put symbols in the dynamic symbol table">;
|
|
|
|
defm version_script: Eq<"version-script", "Read a version script">;
|
|
|
|
def: JoinedOrSeparate<["-"], "z">;
|
|
def: F<"hash-style">;
|
|
def: J<"hash-style=">;
|
|
def: F<"build-id">;
|
|
def: J<"build-id=">;
|
|
def: F<"eh-frame-hdr">;
|
|
def: JoinedOrSeparate<["-"], "m">;
|
|
def: F<"start-group">;
|
|
def: F<"end-group">;
|
|
def: F<"pie">;
|
|
def: F<"fatal-warnings">;
|
|
def: F<"disable-new-dtags">;
|