15#include "llvm/Option/ArgList.h"
16#include "llvm/Support/FileSystem.h"
17#include "llvm/Support/Path.h"
26 const llvm::Triple &Triple,
42 const ArgList &DriverArgs, ArgStringList &CC1Args)
const {
43 if (DriverArgs.hasArg(clang::driver::options::OPT_nostdinc))
48 if (!DriverArgs.hasArg(options::OPT_nobuiltininc)) {
50 llvm::sys::path::append(
P,
"include");
54 if (DriverArgs.hasArg(options::OPT_nostdlibinc))
72 const std::string InstalledDir(
getDriver().Dir);
73 std::string SysRootPath =
75 if (llvm::sys::fs::exists(SysRootPath))
83 Arg *A = Args.getLastArg(options::OPT_stdlib_EQ);
85 StringRef
Value = A->getValue();
86 if (
Value !=
"libc++")
88 << A->getAsString(Args);
95 const llvm::opt::ArgList &DriverArgs,
96 llvm::opt::ArgStringList &CC1Args)
const {
100 if (llvm::sys::fs::exists(
Path)) {
109 ArgStringList &CmdArgs)
const {
111 "Only -lc++ (aka libxx) is supported in this toolchain.");
113 CmdArgs.push_back(
"-lc++");
114 if (Args.hasArg(options::OPT_fexperimental_library))
115 CmdArgs.push_back(
"-lc++experimental");
116 CmdArgs.push_back(
"-lc++abi");
117 CmdArgs.push_back(
"-lunwind");
138 llvm::sys::path::append(
139 Path, Twine(
"libclang_rt." + Component +
"-" +
"mips" + Suffix));
140 return std::string(
Path);
The base class of the type hierarchy.
Driver - Encapsulate logic for constructing compilation processes from a set of gcc-driver-like comma...
std::string SysRoot
sysroot, if present
DiagnosticBuilder Diag(unsigned DiagID) const
std::string Dir
The path the driver executable was in, as invoked from the command line.
const IncludeDirsFunc & includeDirsCallback() const
bool findMIPSMultilibs(const Driver &D, const llvm::Triple &TargetTriple, StringRef Path, const llvm::opt::ArgList &Args, DetectedMultilibs &Result)
The JSON file list parser is used to communicate input to InstallAPI.
@ Result
The result type of a method or function.