llvm-project/lld/lib/Driver/WinLinkOptions.td
Rui Ueyama 508939428d [PECOFF] Ignore /incremental option.
/incremental is an option to enable incremental linking. We will eventually
want to implement the feature for better performance, but in the meantime,
we want to just ignore the option so that the linker does not output unknown
option error when it sees /incremental option.

llvm-svn: 191063
2013-09-20 00:55:37 +00:00

73 lines
2.8 KiB
TableGen

include "llvm/Option/OptParser.td"
// link.exe accepts options starting with either a dash or a slash.
class F<string name> : Flag<["/", "-", "-?"], name>;
multiclass P<string name, string help> {
def "" : Joined<["/", "-", "-?"], name#":">, HelpText<help>;
def _c : Separate<["/", "-", "-?"], name>, Alias<!cast<Option>(name)>;
}
defm base : P<"base", "Base address of the program">;
defm defaultlib : P<"defaultlib", "Add the library to the list of input files">;
defm entry : P<"entry", "Name of entry point symbol">;
// No help text because /failifmismatch is not intended to be used by the user.
defm failifmismatch : P<"failifmismatch", "">;
defm heap : P<"heap", "Size of the heap">;
defm libpath : P<"libpath", "Additional library search path">;
defm mllvm : P<"mllvm", "Options to pass to LLVM">;
defm out : P<"out", "Path to file to write output">;
defm stack : P<"stack", "Size of the stack">;
defm machine : P<"machine", "Specify target platform">;
defm version : P<"version", "Specify a version number in the PE header">;
defm subsystem : P<"subsystem", "Specify subsystem">;
// We cannot use multiclass P because class name "incl" is different
// from its command line option name. We do this because "include" is
// a reserved keyword in tablegen.
def incl : Joined<["/", "-"], "include:">,
HelpText<"Force symbol to be added to symbol table as undefined one">;
def incl_c : Separate<["/", "-"], "include">, Alias<incl>;
def force : F<"force">,
HelpText<"Allow undefined symbols when creating executables">;
def force_unresolved : F<"force:unresolved">;
def ref : F<"opt:ref">;
def no_ref : F<"opt:noref">,
HelpText<"Keep unreferenced symbols to be included to the output">;
def nxcompat : F<"nxcompat">;
def no_nxcompat : F<"nxcompat:no">,
HelpText<"Disable data execution provention">;
def largeaddressaware : F<"largeaddressaware">;
def no_largeaddressaware : F<"largeaddressaware:no">,
HelpText<"Disable large addresses">;
def fixed : F<"fixed">;
def no_fixed : F<"fixed:no">, HelpText<"Enable base relocations">;
def dynamicbase : F<"dynamicbase">;
def no_dynamicbase : F<"dynamicbase:no">, HelpText<"Disable address space layout randomization">;
def tsaware : F<"tsaware">;
def no_tsaware : F<"tsaware:no">,
HelpText<"Create non-Terminal Server aware executable">;
def help : F<"help">;
def help_q : F<"?">, Alias<help>;
def DASH_DASH : Option<["--"], "", KIND_REMAINING_ARGS>;
// The flags below do nothing. They are defined only for link.exe compatibility.
multiclass Q<string name> {
def "" : Joined<["/", "-", "-?"], name#":">;
def _c : Separate<["/", "-", "-?"], name>, Alias<!cast<Option>(name)>;
}
def nologo : F<"nologo">;
defm errorreport : Q<"errorreport">;
def incremental : F<"incremental">;
def no_incremental : F<"incremental:no">;