Frontend: Don't automatically create missing directories when using temporary files with createOutputFile()

- This would otherwise happen as a side effect of llvm::sys::fs::unique_file creating parent directories.

llvm-svn: 151960
This commit is contained in:
Daniel Dunbar
2012-03-03 00:36:02 +00:00
parent 62a58f4928
commit b9c62c0773
3 changed files with 28 additions and 9 deletions

View File

@@ -340,7 +340,8 @@ bool GenerateModuleAction::ComputeASTConsumerArguments(CompilerInstance &CI,
// We use a temporary to avoid race conditions.
OS = CI.createOutputFile(CI.getFrontendOpts().OutputFile, /*Binary=*/true,
/*RemoveFileOnSignal=*/false, InFile,
/*Extension=*/"", /*useTemporary=*/true);
/*Extension=*/"", /*useTemporary=*/true,
/*CreateMissingDirectories=*/true);
if (!OS)
return true;