Mesa (master): scons: Fix Windows builds with LLVM 3.5.

Jose Fonseca jrfonseca at kemper.freedesktop.org
Tue Feb 3 10:19:11 UTC 2015


Module: Mesa
Branch: master
Commit: 5b941ce8575089279b92797f7c10aa294cbc16c8
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=5b941ce8575089279b92797f7c10aa294cbc16c8

Author: Jose Fonseca <jfonseca at vmware.com>
Date:   Tue Feb  3 10:16:50 2015 +0000

scons: Fix Windows builds with LLVM 3.5.

LLVMBitReader dependency was introduced, as pointed out by Rob Conde.

---

 scons/llvm.py |   16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/scons/llvm.py b/scons/llvm.py
index 1e312f9..d145de8 100644
--- a/scons/llvm.py
+++ b/scons/llvm.py
@@ -98,8 +98,20 @@ def generate(env):
             'HAVE_STDINT_H',
         ])
         env.Prepend(LIBPATH = [os.path.join(llvm_dir, 'lib')])
-        if True:
-            # 3.2
+        # LIBS should match the output of `llvm-config --libs engine mcjit bitwriter x86asmprinter`
+        if llvm_version >= distutils.version.LooseVersion('3.5'):
+            env.Prepend(LIBS = [
+                'LLVMBitWriter', 'LLVMMCJIT', 'LLVMRuntimeDyld',
+                'LLVMX86Disassembler', 'LLVMX86AsmParser', 'LLVMX86CodeGen',
+                'LLVMSelectionDAG', 'LLVMAsmPrinter', 'LLVMX86Desc',
+                'LLVMObject', 'LLVMMCParser', 'LLVMBitReader', 'LLVMX86Info',
+                'LLVMX86AsmPrinter', 'LLVMX86Utils', 'LLVMJIT',
+                'LLVMExecutionEngine', 'LLVMCodeGen', 'LLVMScalarOpts',
+                'LLVMInstCombine', 'LLVMTransformUtils', 'LLVMipa',
+                'LLVMAnalysis', 'LLVMTarget', 'LLVMMC', 'LLVMCore',
+                'LLVMSupport'
+            ])
+        else:
             env.Prepend(LIBS = [
                 'LLVMBitWriter', 'LLVMX86Disassembler', 'LLVMX86AsmParser',
                 'LLVMX86CodeGen', 'LLVMX86Desc', 'LLVMSelectionDAG',




More information about the mesa-commit mailing list