xref: /llvm-project/clang/tools/clang-scan-deps/Opts.td (revision 6a4eaf9b33d8091b7d09b2a30a3fc8993a01db31)
1384fca55SAlex Brachetinclude "llvm/Option/OptParser.td"
2384fca55SAlex Brachet
3384fca55SAlex Brachetclass F<string name, string help> : Flag<["-"], name>, HelpText<help>;
4384fca55SAlex Brachetclass Arg<string name, string help> : Separate<["-"], name>, HelpText<help>;
5384fca55SAlex Brachet
6384fca55SAlex Brachetmulticlass Eq<string name, string help> {
7384fca55SAlex Brachet    def NAME #_EQ : Joined<["-", "--"], name #"=">, HelpText<help>;
8384fca55SAlex Brachet    def : Separate<["-", "--"], name>, Alias<!cast<Joined>(NAME #_EQ)>;
9384fca55SAlex Brachet}
10384fca55SAlex Brachet
11384fca55SAlex Brachetdef help : Flag<["--"], "help">, HelpText<"Display this help">;
12384fca55SAlex Brachetdef version : Flag<["--"], "version">, HelpText<"Display the version">;
13384fca55SAlex Brachet
14*6a4eaf9bSJan Svobodadef o : Arg<"o", "Destination of the primary output">;
15*6a4eaf9bSJan Svoboda
16384fca55SAlex Brachetdefm mode : Eq<"mode", "The preprocessing mode used to compute the dependencies">;
17384fca55SAlex Brachet
18384fca55SAlex Brachetdefm format : Eq<"format", "The output format for the dependencies">;
19384fca55SAlex Brachet
20384fca55SAlex Brachetdefm module_files_dir : Eq<"module-files-dir",
21384fca55SAlex Brachet    "The build directory for modules. Defaults to the value of '-fmodules-cache-path=' from command lines for implicit modules">;
22384fca55SAlex Brachet
23fb07d9ccSMichael Spencerdef optimize_args_EQ : CommaJoined<["-", "--"], "optimize-args=">, HelpText<"Which command-line arguments of modules to optimize">;
24384fca55SAlex Brachetdef eager_load_pcm : F<"eager-load-pcm", "Load PCM files eagerly (instead of lazily on import)">;
25384fca55SAlex Brachet
26384fca55SAlex Brachetdef j : Arg<"j", "Number of worker threads to use (default: use all concurrent threads)">;
27384fca55SAlex Brachet
28384fca55SAlex Brachetdefm compilation_database : Eq<"compilation-database", "Compilation database">;
29384fca55SAlex Brachetdefm module_name : Eq<"module-name", "the module of which the dependencies are to be computed">;
30384fca55SAlex Brachetdefm dependency_target : Eq<"dependency-target", "The names of dependency targets for the dependency file">;
31384fca55SAlex Brachet
32384fca55SAlex Brachetdef deprecated_driver_command : F<"deprecated-driver-command", "use a single driver command to build the tu (deprecated)">;
33384fca55SAlex Brachet
34384fca55SAlex Brachetdefm resource_dir_recipe : Eq<"resource-dir-recipe", "How to produce missing '-resource-dir' argument">;
35384fca55SAlex Brachet
36e766e3afSJan Svobodadef print_timing : F<"print-timing", "Print timing information">;
37e766e3afSJan Svoboda
38384fca55SAlex Brachetdef verbose : F<"v", "Use verbose output">;
39384fca55SAlex Brachet
40384fca55SAlex Brachetdef round_trip_args : F<"round-trip-args", "verify that command-line arguments are canonical by parsing and re-serializing">;
41384fca55SAlex Brachet
42384fca55SAlex Brachetdef DASH_DASH : Option<["--"], "", KIND_REMAINING_ARGS>;
43