<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">It looks like it's not linking in the [correct] output from the Qt moc.<DIV><BR class="khtml-block-placeholder"></DIV><DIV>When you ran 'cmake', did you select a Debug or Release build? If you selected Release in 'cmake', try setting the configuration to Release in VS 2005 and then rebuild.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Michael<DIV><BR><DIV><DIV>On Jul 19, 2006, at 2:56 PM, Wang, Haobing wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"> <DIV class="Section1"><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial">Hello,<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial"><O:P> </O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial">I am trying to compile VTK5.0 with QT4.1.4 using Visual C++ 2005. When compiling QVTK, I got the following errors:<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial"><O:P> </O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>------ Build started: Project: QVTK, Configuration: Debug Win32 ------<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>Linking...<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2> Creating library D:\vtk\VTK\bin\Debug\QVTK.lib and object D:\vtk\VTK\bin\Debug\QVTK.exp<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>vtkEventQtSlotConnect.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall vtkQtConnection::metaObject(void)const " (?metaObject@vtkQtConnection@@UBEPBUQMetaObject@@XZ)<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>vtkEventQtSlotConnect.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall vtkQtConnection::qt_metacast(char const *)" (?qt_metacast@vtkQtConnection@@UAEPAXPBD@Z)<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>vtkEventQtSlotConnect.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall vtkQtConnection::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@vtkQtConnection@@UAEHW4Call@QMetaObject@@HPAPAX@Z)<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>vtkEventQtSlotConnect.obj : error LNK2019: unresolved external symbol "protected: void __thiscall vtkQtConnection::EmitExecute(class vtkObject *,unsigned long,void *,void *,class vtkCommand *)" (?EmitExecute@vtkQtConnection@@IAEXPAVvtkObject@@KPAX1PAVvtkCommand@@@Z) referenced in function "public: void __thiscall vtkQtConnection::Execute(class vtkObject *,unsigned long,void *)" (?Execute@vtkQtConnection@@QAEXPAVvtkObject@@KPAX@Z)<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>D:\vtk\VTK\bin\Debug\QVTK.dll : fatal error LNK1120: 4 unresolved externals<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>Build log was saved at "<A href="file://d">file://d</A>:\vtk\VTK\GUISupport\Qt\QVTK.dir\Debug\BuildLog.htm"<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">2>QVTK - 5 error(s), 0 warning(s)<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""="">========== Build: 1 succeeded, 1 failed, 20 up-to-date, 0 skipped ==========<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="1" face="Courier New"><SPAN style="font-size:8.0pt; font-family:" courier="" new""=""><O:P> </O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial">I tried to link all the libraries in VTK and QT, but still got those errors. Does anyone know what the problem is and how to solve it? Thanks a lot in advance.<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial"><O:P> </O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial">Haobing<O:P></O:P></SPAN></FONT></P><P class="MsoNormal"><FONT size="2" face="Arial"><SPAN style="font-size:10.0pt; font-family:Arial"><O:P> </O:P></SPAN></FONT></P> </DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">_______________________________________________</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">This is the private VTK discussion list.<SPAN class="Apple-converted-space"> </SPAN></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Please keep messages on-topic. Check the FAQ at: <A href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</A></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Follow this link to subscribe/unsubscribe:</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</A></DIV> </BLOCKQUOTE></DIV><BR></DIV></DIV></BODY></HTML>