From 96e938f62c729fab74601627d54c9c4cf499ebdf Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Fri, 6 Nov 2009 15:08:05 +0000 Subject: [PATCH] llvmpipe: Fix build with llvm 2.6. Fixes bug 24949. --- src/gallium/drivers/llvmpipe/lp_bld_misc.cpp | 7 +++---- src/gallium/drivers/llvmpipe/lp_bld_misc.h | 8 +++++++- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/llvmpipe/lp_bld_misc.cpp b/src/gallium/drivers/llvmpipe/lp_bld_misc.cpp index c9acaf1f16c..d3f78c06d92 100644 --- a/src/gallium/drivers/llvmpipe/lp_bld_misc.cpp +++ b/src/gallium/drivers/llvmpipe/lp_bld_misc.cpp @@ -26,8 +26,6 @@ **************************************************************************/ -#include "llvm/Config/config.h" - #include "pipe/p_config.h" #include "lp_bld_misc.h" @@ -50,12 +48,13 @@ LLVMLinkInJIT(void) extern "C" int X86TargetMachineModule; -void +int LLVMInitializeNativeTarget(void) { #if defined(PIPE_ARCH_X86) || defined(PIPE_ARCH_X86_64) - X86TargetMachineModule = 1; + X86TargetMachineModule = 1; #endif + return 0; } diff --git a/src/gallium/drivers/llvmpipe/lp_bld_misc.h b/src/gallium/drivers/llvmpipe/lp_bld_misc.h index 51a84c5e258..0e787e0b9cb 100644 --- a/src/gallium/drivers/llvmpipe/lp_bld_misc.h +++ b/src/gallium/drivers/llvmpipe/lp_bld_misc.h @@ -30,17 +30,23 @@ #define LP_BLD_MISC_H +#include "llvm/Config/config.h" + #ifdef __cplusplus extern "C" { #endif +#ifndef LLVM_NATIVE_ARCH + void LLVMLinkInJIT(void); -void +int LLVMInitializeNativeTarget(void); +#endif /* !LLVM_NATIVE_ARCH */ + #ifdef __cplusplus } -- 2.30.2