Hi
I’ve been using ITK and Qt for a long time on windows. I am now trying to compile my soft on ubuntu 18.04 . ITK compiles well, the tests are OK. When linking my soft, I get the errors below. Has someone any idea ?
Thank you
/usr/local/lib/libITKCommon-5.1.a(itkNumberToString.cxx.o): In function itk::NumberToString<double>::operator()[abi:cxx11](double)': itkNumberToString.cxx:(.text+0x29): undefined reference to
double_conversion::DoubleToStringConverter::EcmaScriptConverter()’
itkNumberToString.cxx:(.text+0x5a):Makefile:493: recipe for target ‘…/magicsIMNC’ failed
undefined reference to double_conversion::DoubleToStringConverter::ToShortestIeeeNumber(double, double_conversion::StringBuilder*, double_conversion::DoubleToStringConverter::DtoaMode) const' /usr/local/lib/libITKCommon-5.1.a(itkNumberToString.cxx.o): In function
itk::NumberToString::operator()abi:cxx11’:
itkNumberToString.cxx:(.text+0x28a): undefined reference to double_conversion::DoubleToStringConverter::EcmaScriptConverter()' itkNumberToString.cxx:(.text+0x2d0): undefined reference to
double_conversion::DoubleToStringConverter::ToShortestIeeeNumber(double, double_conversion::StringBuilder*, double_conversion::DoubleToStringConverter::DtoaMode) const’
/usr/local/lib/libITKCommon-5.1.a(itkDynamicLoader.cxx.o): In function itk::DynamicLoader::OpenLibrary(char const*)': itkDynamicLoader.cxx:(.text+0xc8): undefined reference to
itksys::DynamicLoader::OpenLibrary(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)’
/usr/local/lib/libITKCommon-5.1.a(itkDynamicLoader.cxx.o): In function itk::DynamicLoader::GetSymbolAddress(void*, char const*)': itkDynamicLoader.cxx:(.text+0x213): undefined reference to
itksys::DynamicLoader::GetSymbolAddress(void*, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)’
/usr/local/lib/libITKCommon-5.1.a(itkDynamicLoader.cxx.o): In function itk::DynamicLoader::CloseLibrary(void*)': itkDynamicLoader.cxx:(.text+0x191): undefined reference to
itksys::DynamicLoader::CloseLibrary(void*)’
/usr/local/lib/libITKCommon-5.1.a(itkDynamicLoader.cxx.o): In function itk::DynamicLoader::LastError()': itkDynamicLoader.cxx:(.text+0x301): undefined reference to
itksys::DynamicLoader::LastError()’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::~Directory()': itkDirectory.cxx:(.text+0x24): undefined reference to
itksys::Directory::~Directory()’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::Directory()': itkDirectory.cxx:(.text+0x8b): undefined reference to
itksys::Directory::Directory()’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::Load(char const*)': itkDirectory.cxx:(.text+0x134): undefined reference to
itksys::Directory::Load(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::PrintSelf(std::ostream&, itk::Indent) const': itkDirectory.cxx:(.text+0x26a): undefined reference to
itksys::Directory::GetPath() const’
itkDirectory.cxx:(.text+0x2d5): undefined reference to itksys::Directory::GetNumberOfFiles() const' itkDirectory.cxx:(.text+0x337): undefined reference to
itksys::Directory::GetFile(unsigned long) const’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::GetNumberOfFiles()': itkDirectory.cxx:(.text+0x205): undefined reference to
itksys::Directory::GetNumberOfFiles() const’
/usr/local/lib/libITKCommon-5.1.a(itkDirectory.cxx.o): In function itk::Directory::GetFile(unsigned int)': itkDirectory.cxx:(.text+0x217): undefined reference to
itksys::Directory::GetFile(unsigned long) const’
collect2: error: ld returned 1 exit status
make: *** […/yyy] Error 1
23:00:12: Le processus “/usr/bin/make” s’est terminé avec le code 2.
Erreur lors de la compilation/déploiement du projet magicsIMNC (kit : Desktop Qt 5.12.5 GCC 64bit)
When executing step “Make”
The command is
g++ -Wl,-O1 -o …/yyy list-of-myfiles.o -L/usr/local/lib -litkdouble-conversion-5.1 -litknetlib-5.1 -lITKOptimizers-5.1 -litkvnl_algo-5.1 -litkvnl-5.1 -lITKVNLInstantiation-5.1 -lITKOptimizersv4-5.1 -lITKStatistics-5.1 -litkv3p_netlib-5.1 -litksys-5.1 -lITKCommon-5.1 -ldl -lpthread /home/xxx/Qt/5.12.5/gcc_64/lib/libQt5PrintSupport.so /home/xxx/Qt/5.12.5/gcc_64/lib/libQt5Widgets.so /home/xxx/Qt/5.12.5/gcc_64/lib/libQt5Gui.so /home/xxx/Qt/5.12.5/gcc_64/lib/libQt5Concurrent.so /home/xxx/Qt/5.12.5/gcc_64/lib/libQt5Core.so -lGL