[Mesa-dev] [PATCH] scons: Use LLVM shared library if found.
Jose Fonseca
jfonseca at vmware.com
Fri May 17 12:31:08 PDT 2013
----- Original Message -----
> On Fri, May 17, 2013 at 7:44 AM, Jose Fonseca <jfonseca at vmware.com> wrote:
> > Vinson,
> >
> > Why is this necessary?
> >
> > (I'd prefer that LLVM is statically linked by default. )
> >
> > Jose
>
> The SCons build fails on systems that only provide a LLVM shared
> library. 'llvm-config --libs' always enumerates the libraries instead
> of providing the shared library on such systems.
>
> $ cat /etc/redhat-release
> Fedora release 18 (Spherical Cow)
> $ llvm-config --libs
> -lLLVMAsmParser -lLLVMInstrumentation -lLLVMLinker -lLLVMArchive
> -lLLVMBitReader -lLLVMDebugInfo -lLLVMJIT -lLLVMipo -lLLVMVectorize
> -lLLVMBitWriter -lLLVMTableGen -lLLVMHexagonCodeGen -lLLVMHexagonDesc
> -lLLVMHexagonAsmPrinter -lLLVMHexagonInfo -lLLVMNVPTXCodeGen
> -lLLVMNVPTXDesc -lLLVMNVPTXInfo -lLLVMNVPTXAsmPrinter
> -lLLVMMBlazeDisassembler -lLLVMMBlazeAsmParser -lLLVMMBlazeCodeGen
> -lLLVMMBlazeDesc -lLLVMMBlazeInfo -lLLVMMBlazeAsmPrinter
> -lLLVMCppBackendCodeGen -lLLVMCppBackendInfo -lLLVMMSP430CodeGen
> -lLLVMMSP430Desc -lLLVMMSP430Info -lLLVMMSP430AsmPrinter
> -lLLVMXCoreCodeGen -lLLVMXCoreDesc -lLLVMXCoreInfo
> -lLLVMCellSPUCodeGen -lLLVMCellSPUDesc -lLLVMCellSPUInfo
> -lLLVMMipsDisassembler -lLLVMMipsAsmParser -lLLVMMipsCodeGen
> -lLLVMMipsDesc -lLLVMMipsInfo -lLLVMMipsAsmPrinter
> -lLLVMARMDisassembler -lLLVMARMAsmParser -lLLVMARMCodeGen
> -lLLVMARMDesc -lLLVMARMInfo -lLLVMARMAsmPrinter -lLLVMPowerPCCodeGen
> -lLLVMPowerPCDesc -lLLVMPowerPCInfo -lLLVMPowerPCAsmPrinter
> -lLLVMSparcCodeGen -lLLVMSparcDesc -lLLVMSparcInfo -lLLVMX86AsmParser
> -lLLVMX86Disassembler -lLLVMX86CodeGen -lLLVMX86Desc -lLLVMX86Info
> -lLLVMX86AsmPrinter -lLLVMX86Utils -lLLVMR600CodeGen
> -lLLVMSelectionDAG -lLLVMAsmPrinter -lLLVMR600Desc -lLLVMR600Info
> -lLLVMR600AsmPrinter -lLLVMMCDisassembler -lLLVMMCParser
> -lLLVMInterpreter -lLLVMCodeGen -lLLVMScalarOpts -lLLVMInstCombine
> -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMMCJIT
> -lLLVMRuntimeDyld -lLLVMExecutionEngine -lLLVMTarget -lLLVMMC
> -lLLVMObject -lLLVMCore -lLLVMSupport
> $ ls `llvm-config --libdir`
> BugpointPasses.so libclang.so libLLVM-3.2svn.so libLTO.so
> libprofile_rt.so LLVMgold.so
Then Fedora 18's llvm-config is busted, as `llvm-config --libs` should return libLLVM-3.2svn.so
So I believe this issue should be filled against Fedora, not worked around here. Honestly, only shipping LLVM in a .so is already a bad idea, but breaking llvm-config is even worse -- what the point of scripts like llvm-config if their output can't be trusted?
BTW, configure.ac doesn't have this hack. Does it fail the same way too?
Jose
More information about the mesa-dev
mailing list