diff options
author | Mikhail Glushenkov <foldr@codedgers.com> | 2009-07-04 14:23:32 +0000 |
---|---|---|
committer | Mikhail Glushenkov <foldr@codedgers.com> | 2009-07-04 14:23:32 +0000 |
commit | 4f0fa1539ce32c9a38854d0d6952b03348841328 (patch) | |
tree | 92c13099746926158c4dca9f5d9b54c9630a13e0 /llvm/lib/CompilerDriver/Main.cpp | |
parent | 9297a52715f96beef84ee5e6c89bb2dc58d03d3c (diff) | |
download | bcm5719-llvm-4f0fa1539ce32c9a38854d0d6952b03348841328.tar.gz bcm5719-llvm-4f0fa1539ce32c9a38854d0d6952b03348841328.zip |
Make -save-temps=obj play better with -o.
Use only the *dirname* of the pathname given to -o, so that -o can still be used
to name the output executable. This is more like what GCC 4.5 does.
llvm-svn: 74790
Diffstat (limited to 'llvm/lib/CompilerDriver/Main.cpp')
-rw-r--r-- | llvm/lib/CompilerDriver/Main.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CompilerDriver/Main.cpp b/llvm/lib/CompilerDriver/Main.cpp index c9c0413028d..7d1a3d8fbc4 100644 --- a/llvm/lib/CompilerDriver/Main.cpp +++ b/llvm/lib/CompilerDriver/Main.cpp @@ -37,6 +37,7 @@ namespace { } else if (SaveTemps == SaveTempsEnum::Obj && !OutputFilename.empty()) { tempDir = OutputFilename; + tempDir = tempDir.getDirname(); if (!tempDir.exists()) { std::string ErrMsg; |