From 0da3d3b5baa78f0a91ac394f264f4944e21a8415 Mon Sep 17 00:00:00 2001 From: Aaron Watry Date: Thu, 18 Jul 2013 21:24:35 +0000 Subject: [PATCH] Fix build with LLVM 3.4 F_Binary and friends were moved to include/Support/FileSystem.h v2: Maintain compatibility with LLVM 3.3 Signed-off-by: Aaron Watry llvm-svn: 186610 --- libclc/utils/prepare-builtins.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libclc/utils/prepare-builtins.cpp b/libclc/utils/prepare-builtins.cpp index be1624b..4ad21e8 100644 --- a/libclc/utils/prepare-builtins.cpp +++ b/libclc/utils/prepare-builtins.cpp @@ -10,6 +10,7 @@ #include "llvm/Support/raw_ostream.h" #include "llvm/Support/system_error.h" #include "llvm/Support/ToolOutputFile.h" +#include "llvm/Config/config.h" using namespace llvm; @@ -66,7 +67,11 @@ int main(int argc, char **argv) { std::string ErrorInfo; OwningPtr Out (new tool_output_file(OutputFilename.c_str(), ErrorInfo, +#if LLVM_VERSION_MAJOR > 3 || (LLVM_VERSION_MAJOR == 3 && LLVM_VERSION_MINOR > 3) + sys::fs::F_Binary)); +#else raw_fd_ostream::F_Binary)); +#endif if (!ErrorInfo.empty()) { errs() << ErrorInfo << '\n'; exit(1); -- 2.7.4