[Insight-users] MSVC Error in compiling the FLTK example program

Luis Ibanez luis.ibanez at kitware.com
Fri Jun 25 19:52:10 EDT 2004


Hi Paulus,

The DICOMAppHelper symbol should be in the library


            ITKDICOMParser.lib

Please try adding this library to your
TARGET_LINK_LIBRARIES command.

It should look like

TARGET_LINK_LIBRARIES(myProject itkIO itkBasicFilters itkCommon
itkNumerics ITKDICOMParser fltkd fltkgld fltkimagesd fltkformsd 
${FLTK_LIBRARIES})


However... it is suspicious that you have to manually add this
library.  I wonder if you are building your application for
Release and you built ITK for Debug or the other way around.

You should not mix compilation modes under Windows....


---


Let us know if you find any other problem,


   Thanks



      Luis



-----------------
paulus joo wrote:

> Hi luis and ITK Users
>  
> Many thanks for the help you give.
>  
> I start to use FLTK (windows) and I tried the program example as 
> mentioned in the ITK tutorial Getting Started IV. I make Cmakelist.txt, 
> myProject.cxx and make myProjectGUI.fl with fluid. Project file 
> generation using CMake was succeed. In the compilation stage, there were 
> no error in compiling myproject.cxx, myprojectGUI.cxx but it stoped in 
> the lingking stage. There were 90 error that almost the same, such as: 
> Creating library Debug/myProject.lib and object Debug/myProject.exp
> itkIO.lib(itkDICOMImageIO2.obj) : error LNK2001: unresolved external 
> symbol "public: __thiscall DICOMAppHelper::DICOMAppHelper(void)" 
> (??0DICOMAppHelper@@QAE at XZ <mailto:??0DICOMAppHelper@@QAE at XZ>)
> itkIO.lib(itkDICOMImageIO2.obj) : error LNK2001: unresolved external 
> symbol "public: __thiscall DICOMParser::DICOMParser(void)" 
> (??0DICOMParser@@QAE at XZ <mailto:??0DICOMParser@@QAE at XZ>)
> ....
> Would you mind to show me what should I do?
> I am sorry this error maybe caused by the wrong setting in my MSVC++, 
> and I am really don't know how to fix it. 
> I use fltk and fluid 1.1.4.
>  
> Many thanks in advance.
>  
>  
>  
> // ------CMakelist.txt ---
> PROJECT(myProjectGUI)
>  
> # first we have to find VTK
> FIND_PACKAGE(ITK)
> IF(ITK_FOUND)
>   INCLUDE(${ITK_USE_FILE})
> ENDIF(ITK_FOUND)
>  
> # then FLTK
> FIND_PACKAGE(FLTK)
> IF(FLTK_FOUND)
>   INCLUDE_DIRECTORIES(${FLTK_INCLUDE_DIR})
> ENDIF(FLTK_FOUND)
>  
> ADD_EXECUTABLE(myProject myProject.cxx)
> IF(FLTK_FOUND)
>   FLTK_WRAP_UI(myProject myProjectGUI.fl)
> ENDIF(FLTK_FOUND)
>  
> TARGET_LINK_LIBRARIES(myProject itkIO itkBasicFilters itkCommon 
> itkNumerics fltkd fltkgld fltkimagesd fltkformsd ${FLTK_LIBRARIES})
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users





More information about the Insight-users mailing list