mardi 31 octobre 2017

Undefined reference to std::__sso_string::__sso_string under Centos7 and devtoolset-7

I've got Centos 7 (CentOS Linux release 7.4.1708 (Core)) with installed devtoolset-7 (gcc/g++ 7.2.1) and I'm trying to build application in debug mode using conan and cmake :

cmake .. -DCMAKE_BUILD_TYPE=Debug && make

Compilation goes fine, but when it tries to link application, there's error:

[ 94%] Building CXX object test/CMakeFiles/tests.dir/main.cpp.o
cd /home/mmaka/Projekty/Test/build/test && /opt/rh/devtoolset-7/root/usr/bin/c++   -I/home/mmaka/.conan/data/Catch/1.9.4/uilianries/stable/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include -I/home/mmaka/.conan/data/LicenseVerifier/0.2/mmaka/stable/package/dddbe98cdf0fee1bc0e935b7d9cb55fb6ac91e9d/include -I/home/mmaka/.conan/data/Protobuf/3.3.0/memsharded/testing/package/af539cf88d500e43f07db880ead85caf03eb59f0/include -I/home/mmaka/.conan/data/armadillo/7.950.1/mmaka/stable/package/4738f25476b0f8f9c35b9ffa2ef93fc44ee1be3f/include -I/home/mmaka/.conan/data/civetweb/1.9.1/mmaka/stable/package/30521fa001812a885c3d40af3906c4b0ac52ba13/include -I/home/mmaka/.conan/data/jsoncpp/1.8.0/theirix/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/include -I/home/mmaka/.conan/data/sndfile/1.0.28/mmaka/stable/package/3fc343d7c666aa132d336764f97b890ecc35ebaa/include -I/home/mmaka/.conan/data/soxr/0.1.2/mmaka/stable/package/f5439539398d3f0d2ead69e27fe93b1fc9c27772/include -I/home/mmaka/.conan/data/yaml-cpp/0.5.3/mmaka/stable/package/6a58f30b01a1a6b64beeccaddc7d285c7005ead0/include -I/home/mmaka/.conan/data/Boost/1.64.0/conan/stable/package/d6a3c401aaf63728d6c3923f0431fc81dc9c77d1/include -I/home/mmaka/.conan/data/FLAC/1.3.1/Outurnate/stable/package/b90c1b060ffc91d076415439aaf03a44b60edd18/include -I/home/mmaka/.conan/data/Logging/0.1/mmaka/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/include -I/home/mmaka/.conan/data/OpenBLAS/0.2.19/mmaka/stable/package/6c3feb804f9f9215b3dcb50ece3a2a312634ba12/include -I/home/mmaka/.conan/data/cryptopp/5.6.5/hykersec/testing/package/2aefc0b964f0d251f8fb69f3a8450427b24224ea/include -I/home/mmaka/.conan/data/sigar/1.6.4/mmaka/stable/package/510b4fc3cf7267f3694200560a1a888c3f06acb2/include -I/home/mmaka/.conan/data/vorbis/1.3.5/Outurnate/stable/package/fb782e536e79ff49249495e9ac27db7dc508bde3/include -I/home/mmaka/.conan/data/bzip2/1.0.6/conan/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/include -I/home/mmaka/.conan/data/ogg/1.3.2/coding3d/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/include -I/home/mmaka/.conan/data/zlib/1.2.11/lasote/stable/package/af29216216700781418277965556f3bb047c2635/include -I/home/mmaka/Projekty/Test/common -I/home/mmaka/Projekty/Test/DSPServerTI -I/home/mmaka/Projekty/Test/DSPServerTI/include -I/home/mmaka/Projekty/Test/DSPServerTI/Utilities -I/home/mmaka/Projekty/Test/DSPServerTI/../SessionManager/FileManager -I/home/mmaka/Projekty/Test/build/DSPServerTI -I/home/mmaka/Projekty/Test/rest -I/home/mmaka/Projekty/Test/test  -g    -DBOOST_USE_STATIC_LIBS -DARMA_USE_CXX11 -DARMA_USE_BLAS -DARMA_DONT_USE_WRAPPER -std=gnu++14 -o CMakeFiles/tests.dir/main.cpp.o -c /home/mmaka/Projekty/Test/test/main.cpp
[ 95%] Linking CXX executable ../bin/tests
cd /home/mmaka/Projekty/Test/build/test && /usr/local/bin/cmake -E cmake_link_script CMakeFiles/tests.dir/link.txt --verbose=1
/opt/rh/devtoolset-7/root/usr/bin/c++     -g        CMakeFiles/tests.dir/main.cpp.o CMakeFiles/http://ift.tt/2A00Yn3 CMakeFiles/http://ift.tt/2xE9oPG CMakeFiles/http://ift.tt/2A1WYTj CMakeFiles/http://ift.tt/2xE7a2u CMakeFiles/http://ift.tt/2A1WZql CMakeFiles/http://ift.tt/2xBxF8J CMakeFiles/http://ift.tt/2A1WZXn  -o ../bin/tests  -L/home/mmaka/.conan/data/LicenseVerifier/0.2/mmaka/stable/package/dddbe98cdf0fee1bc0e935b7d9cb55fb6ac91e9d/lib  -L/home/mmaka/.conan/data/Protobuf/3.3.0/memsharded/testing/package/af539cf88d500e43f07db880ead85caf03eb59f0/lib  -L/home/mmaka/.conan/data/civetweb/1.9.1/mmaka/stable/package/30521fa001812a885c3d40af3906c4b0ac52ba13/lib  -L/home/mmaka/.conan/data/jsoncpp/1.8.0/theirix/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/lib  -L/home/mmaka/.conan/data/sndfile/1.0.28/mmaka/stable/package/3fc343d7c666aa132d336764f97b890ecc35ebaa/lib  -L/home/mmaka/.conan/data/soxr/0.1.2/mmaka/stable/package/f5439539398d3f0d2ead69e27fe93b1fc9c27772/lib  -L/home/mmaka/.conan/data/yaml-cpp/0.5.3/mmaka/stable/package/6a58f30b01a1a6b64beeccaddc7d285c7005ead0/lib  -L/home/mmaka/.conan/data/Boost/1.64.0/conan/stable/package/d6a3c401aaf63728d6c3923f0431fc81dc9c77d1/lib  -L/home/mmaka/.conan/data/FLAC/1.3.1/Outurnate/stable/package/b90c1b060ffc91d076415439aaf03a44b60edd18/lib  -L/home/mmaka/.conan/data/Logging/0.1/mmaka/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/lib  -L/home/mmaka/.conan/data/OpenBLAS/0.2.19/mmaka/stable/package/6c3feb804f9f9215b3dcb50ece3a2a312634ba12/lib  -L/home/mmaka/.conan/data/cryptopp/5.6.5/hykersec/testing/package/2aefc0b964f0d251f8fb69f3a8450427b24224ea/lib  -L/home/mmaka/.conan/data/sigar/1.6.4/mmaka/stable/package/510b4fc3cf7267f3694200560a1a888c3f06acb2/lib  -L/home/mmaka/.conan/data/vorbis/1.3.5/Outurnate/stable/package/fb782e536e79ff49249495e9ac27db7dc508bde3/lib  -L/home/mmaka/.conan/data/bzip2/1.0.6/conan/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/lib  -L/home/mmaka/.conan/data/ogg/1.3.2/coding3d/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/lib  -L/home/mmaka/.conan/data/zlib/1.2.11/lasote/stable/package/af29216216700781418277965556f3bb047c2635/lib -Wl,-rpath,/home/mmaka/.conan/data/LicenseVerifier/0.2/mmaka/stable/package/dddbe98cdf0fee1bc0e935b7d9cb55fb6ac91e9d/lib:/home/mmaka/.conan/data/Protobuf/3.3.0/memsharded/testing/package/af539cf88d500e43f07db880ead85caf03eb59f0/lib:/home/mmaka/.conan/data/civetweb/1.9.1/mmaka/stable/package/30521fa001812a885c3d40af3906c4b0ac52ba13/lib:/home/mmaka/.conan/data/jsoncpp/1.8.0/theirix/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/lib:/home/mmaka/.conan/data/sndfile/1.0.28/mmaka/stable/package/3fc343d7c666aa132d336764f97b890ecc35ebaa/lib:/home/mmaka/.conan/data/soxr/0.1.2/mmaka/stable/package/f5439539398d3f0d2ead69e27fe93b1fc9c27772/lib:/home/mmaka/.conan/data/yaml-cpp/0.5.3/mmaka/stable/package/6a58f30b01a1a6b64beeccaddc7d285c7005ead0/lib:/home/mmaka/.conan/data/Boost/1.64.0/conan/stable/package/d6a3c401aaf63728d6c3923f0431fc81dc9c77d1/lib:/home/mmaka/.conan/data/FLAC/1.3.1/Outurnate/stable/package/b90c1b060ffc91d076415439aaf03a44b60edd18/lib:/home/mmaka/.conan/data/Logging/0.1/mmaka/stable/package/4d157107cadad2bf785efc05e6135855814d60b0/lib:/home/mmaka/.conan/data/OpenBLAS/0.2.19/mmaka/stable/package/6c3feb804f9f9215b3dcb50ece3a2a312634ba12/lib:/home/mmaka/.conan/data/cryptopp/5.6.5/hykersec/testing/package/2aefc0b964f0d251f8fb69f3a8450427b24224ea/lib:/home/mmaka/.conan/data/sigar/1.6.4/mmaka/stable/package/510b4fc3cf7267f3694200560a1a888c3f06acb2/lib:/home/mmaka/.conan/data/vorbis/1.3.5/Outurnate/stable/package/fb782e536e79ff49249495e9ac27db7dc508bde3/lib:/home/mmaka/.conan/data/bzip2/1.0.6/conan/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/lib:/home/mmaka/.conan/data/ogg/1.3.2/coding3d/stable/package/181529a9eea3709e521af1bd56b4985e73cf35fa/lib:/home/mmaka/.conan/data/zlib/1.2.11/lasote/stable/package/af29216216700781418277965556f3bb047c2635/lib ../DSPServerTI/libDSPServerTI.a ../rest/libmmaka-Test-lib.a ../common/libcommon-dsp-lib.a -lLicensing -lpthread -lprotobuf -lcivetweb -lcivetweb-cxx -lrt -ljsoncpp -lsndfile -lsoxr -lyaml-cpp -lboost_atomic -lboost_system -lboost_chrono -lboost_container -lboost_context -lboost_exception -lboost_date_time -lboost_coroutine -lboost_thread -lboost_fiber -lboost_filesystem -lboost_regex -lboost_iostreams -lboost_graph -lboost_locale -lboost_log -lboost_timer -lboost_log_setup -lboost_math_tr1 -lboost_math_tr1f -lboost_math_tr1l -lboost_math_c99 -lboost_math_c99f -lboost_math_c99l -lboost_unit_test_framework -lboost_random -lboost_program_options -lboost_serialization -lboost_wserialization -lboost_signals -lboost_prg_exec_monitor -lboost_test_exec_monitor -lboost_type_erasure -lboost_wave -lFLAC -lFLAC++ -lLogging -lopenblas -lgfortran -Wl,-Bstatic -lcryptopp -Wl,-Bdynamic -lsigar-amd64-linux -ldl -lvorbis -lvorbisfile -lvorbisenc -lbz2 -logg -lz ../DSPServerTI/libDSPServerTI.a -lLicensing -lpthread -lprotobuf -lcivetweb -lcivetweb-cxx -lrt -ljsoncpp -lsndfile -lsoxr -lyaml-cpp -lboost_atomic -lboost_system -lboost_chrono -lboost_container -lboost_context -lboost_exception -lboost_date_time -lboost_coroutine -lboost_thread -lboost_fiber -lboost_filesystem -lboost_regex -lboost_iostreams -lboost_graph -lboost_locale -lboost_log -lboost_timer -lboost_log_setup -lboost_math_tr1 -lboost_math_tr1f -lboost_math_tr1l -lboost_math_c99 -lboost_math_c99f -lboost_math_c99l -lboost_unit_test_framework -lboost_random -lboost_program_options -lboost_serialization -lboost_wserialization -lboost_signals -lboost_prg_exec_monitor -lboost_test_exec_monitor -lboost_type_erasure -lboost_wave -lFLAC -lFLAC++ -lLogging -lopenblas -lgfortran -Wl,-Bstatic -lcryptopp -Wl,-Bdynamic -lsigar-amd64-linux -ldl -lvorbis -lvorbisfile -lvorbisenc -lbz2 -logg -lz
/opt/rh/devtoolset-7/root/usr/lib/gcc/x86_64-redhat-linux/7/libstdc++_nonshared.a(cow-stdexcept.o): In function `std::__sso_string::__sso_string(std::string const&)':
(.text._ZNSt12__sso_stringC2ERKSs+0x8): undefined reference to `std::__sso_string::__sso_string(char const*, unsigned long)'
/opt/rh/devtoolset-7/root/usr/lib/gcc/x86_64-redhat-linux/7/libstdc++_nonshared.a(cow-stdexcept.o): In function `std::_V2::error_category::_M_message(int) const':
(.text._ZNKSt3_V214error_category10_M_messageEi+0x30): undefined reference to `std::__sso_string::__sso_string(char const*, unsigned long)'
/opt/rh/devtoolset-7/root/usr/libexec/gcc/x86_64-redhat-linux/7/ld: ../bin/tests: hidden symbol `_ZNSt12__sso_stringD1Ev' isn't defined
/opt/rh/devtoolset-7/root/usr/libexec/gcc/x86_64-redhat-linux/7/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
make[3]: *** [test/CMakeFiles/http://ift.tt/2A1X0up: bin/tests] Error 1
make[3]: Leaving directory '/home/mmaka/Projekty/Test/build'
make[2]: *** [CMakeFiles/Makefile2:350: test/CMakeFiles/tests.dir/all] Error 2
make[2]: Leaving directory '/home/mmaka/Projekty/Test/build'
make[1]: *** [CMakeFiles/Makefile2:362: test/CMakeFiles/tests.dir/rule] Error 2
make[1]: Leaving directory '/home/mmaka/Projekty/Test/build'
make: *** [Makefile:197: tests] Error 2

Using c++filt, it says that symbol 'std::__sso_string::~__sso_string()' isn't defined.

Does anyone know how to solve this problem?

Aucun commentaire:

Enregistrer un commentaire