From c2a602d21a4dd7da9d3226a70cb83ab85ceb446a Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Thu, 20 Oct 2016 11:21:26 +0200 Subject: gallivm: try to fix build with LLVM <= 3.4 due to missing CallSite.h Reviewed-by: Brian Paul Tested-by: Brian Paul --- src/gallium/auxiliary/gallivm/lp_bld_misc.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/gallium') diff --git a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp index f4045ad1d89..bd4d4d3c094 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp +++ b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp @@ -77,7 +77,9 @@ #include +#if HAVE_LLVM >= 0x0305 #include +#endif #include #include #include @@ -715,8 +717,10 @@ lp_get_called_value(LLVMValueRef call) { #if HAVE_LLVM >= 0x0309 return LLVMGetCalledValue(call); -#else +#elif HAVE_LLVM >= 0x0305 return llvm::wrap(llvm::CallSite(llvm::unwrap(call)).getCalledValue()); +#else + return NULL; /* radeonsi doesn't support so old LLVM. */ #endif } -- cgit v1.2.3