I’m trying to build cling (rev 42565) with clang/llvm (rev 147279), and getting link errors:
Undefined symbols for architecture x86_64:
"_LLVMInitializeHexagonAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializePTXAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializePowerPCAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeCellSPUAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeARMAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeXCoreAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeMSP430AsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeMipsAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeSparcAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
"_LLVMInitializeMBlazeAsmPrinter", referenced from:
llvm::InitializeAllAsmPrinters() in libclingInterpreter.a(CIFactory.o)
ld: symbol(s) not found for architecture x86_64
I think I’m following the instructions correctly. It appears that clang/llvm build fine; the errors I’m getting are linking cling. I’m basically doing the following:
$ svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
Checked out revision 147279.
$ cd llvm/tools
$ svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
Checked out revision 147279.
$ cd ../projects/
$ svn co http://llvm.org/svn/llvm-project/compiler-rt/trunk compiler-rt
Checked out revision 147279.
$ cd ../tools
$ svn co https://root.cern.ch/svn/root/trunk/cint/cling
Checked out revision 42565.
$ cd ..
$ cat tools/cling/patches/*.diff | patch -p0
patching file tools/Makefile
Hunk #1 succeeded at 21 (offset 7 lines).
$ cd ..
$ mkdir build
$ cd build
$ ../llvm/configure
$ make
Can anyone offer any advice?