[vtkusers] Compiling HelloWorld and other qt based examples - vtk-5.10.0

Billy Araujo billyaraujo at gmail.com
Wed Aug 29 10:48:39 EDT 2012


Hi,

I am using the Cmakefiles provided with VTK. I haven't changed anything. I
just activated: BUILD_EXAMPLES and VTK_USE_QT flags in the configure of
cmake-gui.

I am trying to compile a simple QT viewer to see how VTK works with QT.





On Wed, Aug 29, 2012 at 3:40 PM, David Doria <daviddoria at gmail.com> wrote:

> On Wed, Aug 29, 2012 at 10:36 AM, Billy Araujo <billyaraujo at gmail.com>wrote:
>
>> I get the following link problem compiling vtk 5.10 with QT support. I
>> configured the project with cmake and I am using VS 2010.
>>
>> Error 1 error LNK2019: unresolved external symbol "__declspec(dllimport)
>> public: class QImage & __thiscall QImage::operator=(class QImage &&)"
>> (__imp_??4QImage@@QAEAAV0@$$QAV0@@Z) referenced in function "public:
>> virtual void __thiscall vtkQtLabelRenderStrategy::RenderLabel(int *
>> const,class vtkTextProperty *,class vtkUnicodeString)"
>> (?RenderLabel at vtkQtLabelRenderStrategy@@UAEXQAHPAVvtkTextProperty@
>> @VvtkUnicodeString@@@Z)
>> D:\Libraries\VTK\vtk-5.10.0\Build\msvc10\Examples\Infovis\Cxx\vtkRendering.lib(vtkQtLabelRenderStrategy.obj)
>> HelloWorld
>>
>> I got similar problem with GeovisCxxTests. I changed linking order and it
>> solved it.
>>
>> Any ideas?
>>
>
> Are you linking to QVTK as in this example?
> http://www.vtk.org/Wiki/VTK/Examples/Cxx/Qt/RenderWindowUIMultipleInheritance#CMakeLists.txt
>
> Please show us your CMakeLists.txt file.
>
> For Geovis, as long as you have built VTK with VTK_USE_GEOVIS=ON, you
> should just need to link to the standard ${VTK_LIBRARIES} in the
> target_link_libraries call.
>
> David
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120829/2d8f2e3c/attachment.htm>


More information about the vtkusers mailing list