If clang was configured for a DEFAULT_SYSROOT and no --sysroot argument
is seen, record one with the implicit default. llvm-svn: 288822
This commit is contained in:
parent
cbc872549c
commit
0599a935e5
|
|
@ -4061,6 +4061,11 @@ void Clang::DumpCompilationDatabase(Compilation &C, StringRef Filename,
|
|||
Buf = "-x";
|
||||
Buf += types::getTypeName(Input.getType());
|
||||
CDB << ", \"" << escape(Buf) << "\"";
|
||||
if (!D.SysRoot.empty() && !Args.hasArg(options::OPT__sysroot_EQ)) {
|
||||
Buf = "--sysroot=";
|
||||
Buf += D.SysRoot;
|
||||
CDB << ", \"" << escape(Buf) << "\"";
|
||||
}
|
||||
CDB << ", \"" << escape(Input.getFilename()) << "\"";
|
||||
for (auto &A: Args) {
|
||||
auto &O = A->getOption();
|
||||
|
|
|
|||
Loading…
Reference in New Issue