[Mesa-dev] [PATCH] clover: Fix build with libclang v3.2
Tom Stellard
tom at stellard.net
Mon Sep 24 14:11:17 PDT 2012
From: Tom Stellard <thomas.stellard at amd.com>
---
src/gallium/state_trackers/clover/llvm/invocation.cpp | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp b/src/gallium/state_trackers/clover/llvm/invocation.cpp
index be15e96..1e830cd 100644
--- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
+++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
@@ -120,7 +120,12 @@ namespace {
c.getLangOpts().NoBuiltin = true;
c.getTargetOpts().Triple = triple;
+#if HAVE_LLVM <= 0x0301
c.getInvocation().setLangDefaults(clang::IK_OpenCL);
+#else
+ c.getInvocation().setLangDefaults(c.getLangOpts(), clang::IK_OpenCL,
+ clang::LangStandard::lang_opencl11);
+#endif
c.createDiagnostics(0, NULL, new clang::TextDiagnosticPrinter(
s_log, c.getDiagnosticOpts()));
--
1.7.11.4
More information about the mesa-dev
mailing list