From ec2ac8985650a501b452b8fdb69d3124d7be5af9 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Fri, 4 Oct 2013 21:40:54 +0000 Subject: Fix object file writing in llvm-lto on Windows. We were writing in text mode. Patch by Greg Bedwell. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191985 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/llvm-lto/llvm-lto.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tools/llvm-lto/llvm-lto.cpp') diff --git a/tools/llvm-lto/llvm-lto.cpp b/tools/llvm-lto/llvm-lto.cpp index 1d03fa62a8..bce903fa16 100644 --- a/tools/llvm-lto/llvm-lto.cpp +++ b/tools/llvm-lto/llvm-lto.cpp @@ -136,7 +136,8 @@ int main(int argc, char **argv) { return 1; } - raw_fd_ostream FileStream(OutputFilename.c_str(), ErrorInfo); + raw_fd_ostream FileStream(OutputFilename.c_str(), ErrorInfo, + sys::fs::F_Binary); if (!ErrorInfo.empty()) { errs() << argv[0] << ": error opening the file '" << OutputFilename << "': " << ErrorInfo << "\n"; -- cgit v1.2.3