[Insight-users] itk setup problems in Ubuntu QtCreator

Alessandro notinmyhead at gmail.com
Tue Jul 2 05:47:04 EDT 2013


it seems that you're trying to use static libraries. In this case, you need a CMake project because static libraries need to be in the right order. Otherwise, re-build itk selecting dynamic libraries instead (.so files): dynamic libraries don't require to link them in the exact reference order...


Il giorno 02/lug/2013, alle ore 10.39, pengpeng ha scritto:

> Hello All:
> 
> I want to use itk in QtCreator in Ubuntu.
> What I did is as below:
> In .pro file : 
> I added : 
> INCLUDEPATH+=/usr/local/include/ITK-4.3 
> LIBS += /usr/local/lib/libITKBiasCorrection-4.3.a\ (and so on with all itk
> lib)
> 
> In main.cpp file:
> I added only 3 lines to test
> #include "itkImage.h"
> typedef itk::Image<unsigned short,3> ImageType;
> ImageType::Pointer image=ImageType::New();
> 
> Then I got errors as below:
> 
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_svd+double-.cxx.o):-1: In function
> `vnl_svd<double>::vnl_svd(vnl_matrix<double> const&, double)':
> (.text._ZN7vnl_svdIdEC2ERK10vnl_matrixIdEd[_ZN7vnl_svdIdEC5ERK10vnl_matrixIdEd]+0x26a):-1:
> error: undefined reference to `v3p_netlib_dsvdc_'
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_svd+double-.cxx.o):-1: In function
> `_GLOBAL__sub_I_vnl_svd_double_.cxx':
> (.text.startup+0x2f):-1: error: undefined reference to
> `v3p_netlib_initialize'
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_qr+double-.cxx.o):-1: In function
> `vnl_qr<double>::vnl_qr(vnl_matrix<double> const&)':
> (.text._ZN6vnl_qrIdEC2ERK10vnl_matrixIdE[_ZN6vnl_qrIdEC5ERK10vnl_matrixIdE]+0x14a):-1:
> error: undefined reference to `v3p_netlib_dqrdc_'
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_qr+double-.cxx.o):-1: In function
> `vnl_qr<double>::solve(vnl_vector<double> const&) const':
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_qr+double-.cxx.o):-1: In function
> `vnl_qr<double>::QtB(vnl_vector<double> const&) const':
> /usr/local/lib/libitkvnl_algo-4.3.a(vnl_qr+double-.cxx.o):-1: In function
> `_GLOBAL__sub_I_vnl_qr_double_.cxx':
> (.text.startup+0x2f):-1: error: undefined reference to
> `v3p_netlib_initialize'
> :-1: error: collect2: ld returned 1 exit status
> 
> I can not figure it out, Any reply will be welcome, thanks a lot.
> 
> 
> 
> --
> View this message in context: http://itk-insight-users.2283740.n2.nabble.com/itk-setup-problems-in-Ubuntu-QtCreator-tp7583410.html
> Sent from the ITK Insight Users mailing list archive at Nabble.com.
> _____________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
> 
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
> 
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users



More information about the Insight-users mailing list