Flag -> Glue, the ongoing saga
[oota-llvm.git] / lib / CompilerDriver / Main.cpp
index 0a6613aa77a3b4e4d1f172e88b4c4a9da01cad37..88cfdb21230513e4e7c4b5b5f4369fd736a817ef 100644 (file)
@@ -17,7 +17,7 @@
 #include "llvm/CompilerDriver/Error.h"
 
 #include "llvm/Support/raw_ostream.h"
-#include "llvm/System/Path.h"
+#include "llvm/Support/Path.h"
 
 #include <sstream>
 #include <string>
@@ -43,8 +43,7 @@ namespace {
       return 0;
     }
     else if (SaveTemps == SaveTempsEnum::Obj && !OutputFilename.empty()) {
-      tempDir = OutputFilename;
-      tempDir = tempDir.getDirname();
+      tempDir = sys::path::parent_path(OutputFilename);
     }
     else {
       // SaveTemps == Cwd --> use current dir (leave tempDir empty).