[vtkusers] compiling error : undefined reference in QVTKWidget.cxx
kun
raistlinliu1225 at gmail.com
Tue Nov 16 11:54:54 EST 2010
I am looking for some help.
I'm trying to use Qt and QVTKWidget.
I do this in eclipse with Qt plugin.
when I try to compile the example code in VTK/Examples/GUI/QT/graphicsview,
I get a lot of similar error messages like:
QVTKWidget.cxx:(.text+0x2c80): undefined reference to
`vtkOStreamWrapper::operator<<(char const*)'
QVTKWidget.cxx:(.text+0x2c8d): undefined reference to
`vtkOStreamWrapper::operator<<(char const*)'
......................
/home/liu/usr/local/lib/vtk-5.6//libQVTK.a(moc_QVTKWidget.cxx.o): In
function `vtkRenderWindowInteractor::GetEnabled()':
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x19):
undefined reference to `vtkObject::GetDebug()'
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x22):
undefined reference to `vtkObject::GetGlobalWarningDisplay()'
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x52):
undefined reference to `vtkOStrStreamWrapper::vtkOStrStreamWrapper()'
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x65):
undefined reference to `vtkObjectBase::GetClassName() const'
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x74):
undefined reference to `vtkObjectBase::GetClassName() const'
moc_QVTKWidget.cxx:(.text._ZN25vtkRenderWindowInteractor10GetEnabledEv[vtkRenderWindowInteractor::GetEnabled()]+0x88):
undefined reference to `vtkOStreamWrapper::operator<<(char const*)'
my pro file is edited to
HEADERS += /usr/local/include/vtk-5.6/
LIBS += -L/usr/local/lib/vtk-5.6/ \
-lvtkRendering \
-lvtkFiltering \
-lvtkGraphics \
-lvtkVolumeRendering \
-lvtkHybrid \
-lvtkImaging \
-lvtkIO \
-lvtkCommon \
-lQVTK \
-Wl,-rpath,/usr/local/lib/vtk-5.6/
--
View this message in context: http://vtk.1045678.n5.nabble.com/compiling-error-undefined-reference-in-QVTKWidget-cxx-tp3267633p3267633.html
Sent from the VTK - Users mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101116/022b4fdb/attachment.htm>
More information about the vtkusers
mailing list