[Insight-users] Linking error

Dora Szasz dora.szasz at yahoo.com
Sat May 21 17:47:43 EDT 2011


Hello!

I am trying to build the example: http://www.insight-journal.org/browse/publication/146 . I used cmake and visual studio to build the example, but when I'm trying to build it the following error appeared: 1>ImageExt.obj : error LNK2019: unresolved external symbol "public: class vtkImageData * __thiscall vtkKWImage::GetVTKImage(void)" (?GetVTKImage at vtkKWImage@@QAEPAVvtkImageData@@XZ) referenced in function __catch$_main$0

This is the CMakeLists.txt: 
cmake_minimum_required(VERSION 2.6)
PROJECT (ImageExt)

FIND_PACKAGE( ITK )
IF ( ITK_FOUND )
INCLUDE( ${ITK_USE_FILE})
ENDIF( ITK_FOUND )

FIND_PACKAGE (VTK)
IF (VTK_FOUND)
INCLUDE ( ${USE_VTK_FILE})
ENDIF (VTK_FOUND)

INCLUDE_DIRECTORIES (${ImageExt_SOURCE_DIR})

ADD_EXECUTABLE( ImageExt ImageExt.cxx )

TARGET_LINK_LIBRARIES (ImageExt ITKBasicFilters ITKCommon ITKIO 

vtkRendering vtkGraphics vtkHybrid vtkImaging vtkIO vtkFiltering vtkCommon)

I don't know how to solve this problem. Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110521/12ebf08a/attachment.htm>


More information about the Insight-users mailing list