compile error with libtbb.so.2
hulin12138 opened this issue · 3 comments
I want to use peregrine in a centos server with gcc-10.1.0 installed from source code.
And I follow the lead of the project, running
source tbb2020/bin/tbbvars.sh
until I meet the errors while running "make", the error says:
`make -C ./core/bliss-0.73
make[1]: enter directory “/home/hulin/gitFile/peregrine/core/bliss-0.73”
rm -f libbliss.a
ar cr libbliss.a defs.o graph.o partition.o orbit.o uintseqhash.o heap.o timer.o utils.o bliss_C.o
ranlib libbliss.a
g++ -I. -g -Wall --pedantic -O9 -fPIC -o bliss bliss.o defs.o graph.o partition.o orbit.o uintseqhash.o heap.o timer.o utils.o bliss_C.o
make[1]: leave directory “/home/hulin/gitFile/peregrine/core/bliss-0.73”
g++ apps/fsm.cc core/DataGraph.o core/PO.o core/utils.o core/PatternGenerator.o /home/hulin/gitFile/peregrine/core/showg.o core/roaring.o -o bin//fsm -L/home/hulin/gitFile/peregrine/core/bliss-0.73/ -lbliss -L/usr/local/lib -lpthread -latomic -Ltbb2020/lib/intel64/gcc4.8 -ltbb -O3 -std=c++2a -Wall -Wextra -Wpedantic -fPIC -fconcepts -I/home/hulin/gitFile/peregrine/core/ -Itbb2020/include
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to ‘typeinfo for std::invalid_argument@GLIBCXX_3.4’
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to‘std::length_error::length_error(std::string const&)@GLIBCXX_3.4’
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to‘std::range_error::range_error(std::string const&)@GLIBCXX_3.4’
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to‘__cxa_allocate_exception@CXXABI_1.3’
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to‘std::bad_alloc::~bad_alloc()@GLIBCXX_3.4’
tbb2020/lib/intel64/gcc4.8/libtbb.so.2:undefined reference to‘__cxa_get_globals@CXXABI_1.3’
... ...
collect2: error : ld return 1`
I am a little confused, and I doubt the tbb2020 doesn't support gcc 10.1.0. What's the possible problem?
Thanks!
Hi!
So these are linker errors talking about undefined references to standard library functions, so this seems like a problem with libstdc++.
Did you compile the corresponding version of libstdc++ alongside gcc 10?
Oh good! Glad it's resolved, sorry I couldn't get back to you sooner.