[Insight-users] ITK application

Luis Ibanez luis.ibanez at kitware.com
Tue Jul 17 11:28:18 EDT 2007


Hi Deepack,

Please read the Tutorials:

     http://www.itk.org/HTML/Tutorials.htm

in particular:

"Gettting Started"
http://www.itk.org/CourseWare/Training/GettingStartedI-WebPage/index.htm

It will show you how to create CMakeLists.txt files for
projects that are based on ITK.


You are cleary missing to include the CMake commands:

       FIND_PACKAGE( ITK REQUIRED )...


Note that some project *already* have their CMakeLists.txt files
customized for being adapted when used outside of InsightApplications.

For example, in

    InsightApplications/RegionGrowing/CMakeLists.txt

you can see lines 4-24:



IF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )

   FIND_PACKAGE(ITK)
   IF(ITK_FOUND)
     INCLUDE(${ITK_USE_FILE})
   ELSE(ITK_FOUND)
     MESSAGE(FATAL_ERROR
      "Cannot build InsightApplications without ITK.  Please set ITK_DIR.")
   ENDIF(ITK_FOUND)

   FIND_PACKAGE(FLTK)
   IF(FLTK_FOUND)
     INCLUDE_DIRECTORIES(${FLTK_INCLUDE_DIR})
   ENDIF(FLTK_FOUND)

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

ENDIF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )




    Regards,


       Luis


=====================
deepak kamboj wrote:
> hi ALL
>         i am using itkapplication.
>          i build itk application successfully and noe i am building 
> sample projcet given in itk application
>          putting it outside the itk directory.
>          when i configure it in cmake it got but it does't show  option 
> of *itk_dir* but it is  giving me .dsw file and when i am building that 
> .dsw file it shows *itkImage.h*  not found
>          please help to get out of that
>         should i need to change cmake file? If than what is the correct 
> cmake file.
>          with BEST REGARDS
>         deepak 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> 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