Silence a warning when assertions are turned off.
[oota-llvm.git] / lib / CompilerDriver / BuiltinOptions.cpp
1 //===--- BuiltinOptions.cpp - The LLVM Compiler Driver ----------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open
6 // Source License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 //  Definitions of all global command-line option variables.
11 //
12 //===----------------------------------------------------------------------===//
13
14 #include "llvm/CompilerDriver/BuiltinOptions.h"
15 #include "llvm/Support/PluginLoader.h"
16
17 namespace cl = llvm::cl;
18
19 // External linkage here is intentional.
20
21 cl::list<std::string> InputFilenames(cl::Positional, cl::desc("<input file>"),
22                                      cl::ZeroOrMore);
23 cl::opt<std::string> OutputFilename("o", cl::desc("Output file name"),
24                                     cl::value_desc("file"), cl::Prefix);
25 cl::list<std::string> Languages("x",
26           cl::desc("Specify the language of the following input files"),
27           cl::ZeroOrMore);
28 cl::opt<bool> DryRun("dry-run",
29                      cl::desc("Only pretend to run commands"));
30 cl::opt<bool> VerboseMode("v",
31                           cl::desc("Enable verbose mode"));
32
33 cl::opt<bool> CheckGraph("check-graph",
34                          cl::desc("Check the compilation graph for errors"),
35                          cl::Hidden);
36 cl::opt<bool> WriteGraph("write-graph",
37                          cl::desc("Write compilation-graph.dot file"),
38                          cl::Hidden);
39 cl::opt<bool> ViewGraph("view-graph",
40                          cl::desc("Show compilation graph in GhostView"),
41                          cl::Hidden);
42
43 cl::opt<SaveTempsEnum::Values> SaveTemps
44 ("save-temps", cl::desc("Keep temporary files"),
45  cl::init(SaveTempsEnum::Unset),
46  cl::values(clEnumValN(SaveTempsEnum::Obj, "obj",
47                        "Save files in the directory specified with -o"),
48             clEnumValN(SaveTempsEnum::Cwd, "cwd",
49                        "Use current working directory"),
50             clEnumValN(SaveTempsEnum::Obj, "", "Same as 'cwd'"),
51             clEnumValEnd),
52  cl::ValueOptional);