[Mesa-dev] [PATCH] clover: Fix build with clang 3.2

Tom Stellard tom at stellard.net
Mon Nov 12 08:04:03 PST 2012


From: Tom Stellard <thomas.stellard at amd.com>

---
 src/gallium/state_trackers/clover/llvm/invocation.cpp | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp b/src/gallium/state_trackers/clover/llvm/invocation.cpp
index 521f998..2b07053 100644
--- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
+++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
@@ -132,7 +132,12 @@ namespace {
                                         clang::LangStandard::lang_opencl11);
 #endif
       c.createDiagnostics(0, NULL, new clang::TextDiagnosticPrinter(
-                          s_log, c.getDiagnosticOpts()));
+                          s_log,
+#if HAVE_LLVM <= 0x0301
+                                 c.getDiagnosticOpts()));
+#else
+                                 &c.getDiagnosticOpts()));
+#endif
 
       c.getPreprocessorOpts().addRemappedFile(name,
                                       llvm::MemoryBuffer::getMemBuffer(source));
-- 
1.7.11.4



More information about the mesa-dev mailing list