Opts.td 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. include "llvm/Option/OptParser.td"
  2. class F<string letter, string help> : Flag<["-"], letter>, HelpText<help>;
  3. class FF<string name, string help> : Flag<["--"], name>, HelpText<help>;
  4. multiclass Eq<string name, string help> {
  5. def NAME #_EQ : Joined<["--"], name #"=">, HelpText<help>;
  6. def : Separate<["--"], name>, Alias<!cast<Joined>(NAME #_EQ)>;
  7. }
  8. defm arch : Eq<"arch", "Specify the architecture, e.g. x86_64">;
  9. defm bitwidth : Eq<"bitwidth", "Specify the bit width">;
  10. defm endianness : Eq<"endianness", "Specify the endianness">;
  11. defm exclude : Eq<"exclude", "Remove symbols which match the pattern. Can be specified multiple times">;
  12. def help : FF<"help", "Display this help">;
  13. def : F<"h", "Alias for --help">, Alias<help>;
  14. defm hint_ifs_target : Eq<"hint-ifs-target", "When --output-format is 'IFS', this flag will hint the expected target triple for IFS output">;
  15. defm input : Eq<"input", "input">;
  16. defm input_format : Eq<"input-format", "Specify the input file format">;
  17. defm output : Eq<"output", "Output file **DEPRECATED**">;
  18. def : Separate<["-"], "o">, HelpText<"Alias for --output">, Alias<output_EQ>;
  19. defm output_elf : Eq<"output-elf", "Output path for ELF file">;
  20. defm output_format : Eq<"output-format", "Specify the output file format **DEPRECATED**">;
  21. defm output_ifs : Eq<"output-ifs", "Output path for IFS file">;
  22. defm output_tbd : Eq<"output-tbd", "Output path for TBD file">;
  23. defm soname : Eq<"soname", "name">;
  24. def strip_ifs_arch : FF<"strip-ifs-arch", "Strip target architecture information away from IFS output">;
  25. def strip_ifs_bitwidth : FF<"strip-ifs-bitwidth", "Strip target bit width information away from IFS output">;
  26. def strip_ifs_endianness : FF<"strip-ifs-endianness", "Strip target endianness information away from IFS output">;
  27. def strip_ifs_target : FF<"strip-ifs-target", "Strip all target information away from IFS output">;
  28. def strip_needed : FF<"strip-needed", "Strip needed libs from output">;
  29. def strip_size : FF<"strip-size", "Remove object size from the output">;
  30. def strip_undefined : FF<"strip-undefined", "Strip undefined symbols from IFS output">;
  31. defm target : Eq<"target", "Specify the target triple, e.g. x86_64-linux-gnu">;
  32. def version : FF<"version", "Display the version">;
  33. def : F<"V", "Alias for --version">, Alias<version>;
  34. def write_if_changed : FF<"write-if-changed", "Write the output file only if it is new or has changed">;