Home | News | Documentation | Download

Installing 6-20-04 fails on Ubuntu 20.04

Dear experts,

I’m trying to install root on an Ubuntu 20.04 machine and I get the following error:

[ 77%] Built target MetaCling
Scanning dependencies of target Cling
[ 77%] Linking CXX executable src/rootcling_stage1
[ 77%] Linking CXX shared library ../../../lib/libCling.so
/usr/bin/ld: ../../interpreter/llvm/src/lib/libclingInterpreter.a(BackendPasses.cpp.o): in function `cling::BackendPasses::CreatePasses(llvm::Module&, int)':
BackendPasses.cpp:(.text._ZN5cling13BackendPasses12CreatePassesERN4llvm6ModuleEi+0x39e): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMCodeGen.a(TargetPassConfig.cpp.o): in function `llvm::TargetPassConfig::addIRPasses()':
TargetPassConfig.cpp:(.text._ZN4llvm16TargetPassConfig11addIRPassesEv+0x1e6): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMCodeGen.a(TargetPassConfig.cpp.o): in function `llvm::TargetPassConfig::addISelPrepare()':
TargetPassConfig.cpp:(.text._ZN4llvm16TargetPassConfig14addISelPrepareEv+0x116): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMCodeGen.a(RegAllocBasic.cpp.o): in function `(anonymous namespace)::RABasic::runOnMachineFunction(llvm::MachineFunction&)':
RegAllocBasic.cpp:(.text._ZN12_GLOBAL__N_17RABasic20runOnMachineFunctionERN4llvm15MachineFunctionE+0x1a5): undefined reference to `llvm::createInlineSpiller(llvm::MachineFunctionPass&, llvm::MachineFunction&, llvm::VirtRegMap&)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMCodeGen.a(RegAllocGreedy.cpp.o): in function `(anonymous namespace)::RAGreedy::runOnMachineFunction(llvm::MachineFunction&)':
RegAllocGreedy.cpp:(.text._ZN12_GLOBAL__N_18RAGreedy20runOnMachineFunctionERN4llvm15MachineFunctionE+0x2a9): undefined reference to `llvm::createInlineSpiller(llvm::MachineFunctionPass&, llvm::MachineFunction&, llvm::VirtRegMap&)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMBitReader.a(BitcodeReader.cpp.o): in function `(anonymous namespace)::BitcodeReader::materialize(llvm::GlobalValue*)':
BitcodeReader.cpp:(.text._ZN12_GLOBAL__N_113BitcodeReader11materializeEPN4llvm11GlobalValueE+0x7c2): undefined reference to `llvm::TBAAVerifier::visitTBAAMetadata(llvm::Instruction&, llvm::MDNode const*)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMipo.a(PassManagerBuilder.cpp.o): in function `llvm::PassManagerBuilder::populateThinLTOPassManager(llvm::legacy::PassManagerBase&)':
PassManagerBuilder.cpp:(.text._ZN4llvm18PassManagerBuilder26populateThinLTOPassManagerERNS_6legacy15PassManagerBaseE+0x7d): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: PassManagerBuilder.cpp:(.text._ZN4llvm18PassManagerBuilder26populateThinLTOPassManagerERNS_6legacy15PassManagerBaseE+0x9e): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: ../../interpreter/llvm/src/lib/libLLVMipo.a(PassManagerBuilder.cpp.o): in function `llvm::PassManagerBuilder::populateLTOPassManager(llvm::legacy::PassManagerBase&)':
PassManagerBuilder.cpp:(.text._ZN4llvm18PassManagerBuilder22populateLTOPassManagerERNS_6legacy15PassManagerBaseE+0xde): undefined reference to `llvm::createVerifierPass(bool)'
/usr/bin/ld: PassManagerBuilder.cpp:(.text._ZN4llvm18PassManagerBuilder22populateLTOPassManagerERNS_6legacy15PassManagerBaseE+0xfe): undefined reference to `llvm::createVerifierPass(bool)'
collect2: error: ld returned 1 exit status
make[2]: *** [core/rootcling_stage1/CMakeFiles/rootcling_stage1.dir/build.make:219: core/rootcling_stage1/src/rootcling_stage1] Error 1
make[1]: *** [CMakeFiles/Makefile2:20006: core/rootcling_stage1/CMakeFiles/rootcling_stage1.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 77%] Built target Cling
make: *** [Makefile:152: all] Error 2

Any suggestions for how to proceed?
Thanks!

ROOT Version: 6.20.04
Platform: Ubuntu 20.04
Compiler: Not Provided


Hi @christok,
How are you building ROOT? Are you using -Dbuiltin_llvm=ON in your build or an external LLVM? Refer to the guide for all the building steps, but also keep in mind that on ubuntu you can just download a precompiled binary.
Cheers,
Vincenzo

Hi Vincenzo,

Thank you for your reply.

I was using these flags : “-Droofit=ON -Dminuit2=ON -Dbuiltin_fftw3=ON” so no, I didn’t try it using -Dbuiltin_llvm=ON as well.

Although, I installed and successfully build v6-16-00 and its working fine now. If I try to build v6-20 with your suggestion, I’ll let you know about the outcome.

Thank you,
Konstantinos