[Insight-developers] Building ITK with Module_ITKVtkGlue forces client applications to find_package(VTK)?

Bill Lorensen bill.lorensen at gmail.com
Tue Jul 3 14:01:34 EDT 2012


Either

1) Rebuild your ITK with that module included.
or
2) As described on each example page:
If you download the entire ITK Wiki Examples Collection, the ItkVtkGlue
directory will be included and configured. If you wish to just build a few
examples, then you will need to download
ItkVtkGlue<http://gitorious.org/itkwikiexamples/itkwikiexamples/blobs/raw/master/ItkVtkGlue.tar.gz>and
build it. When you run cmake it will ask you to specify the location
of
the ItkVtkGlue binary directory.

On Tue, Jul 3, 2012 at 11:16 AM, David Doria <daviddoria at gmail.com> wrote:

> On Tue, Jun 26, 2012 at 1:36 PM, Xiaoxiao Liu <xiaoxiao.liu at kitware.com>wrote:
>
>> Some of my thoughts:
>>
>> 1). I agreed that we haven't take full advantage of modular VTK in ITK
>> yet.
>>      VtkGlue module itself should only depends on several VTK modules
>> instead of entire VTK_LIBRAIRES.
>>
>> 2) When building ITK, ITK_LIBRAIRES should  include all depending
>> libraries turned on by enabled modules.
>>    Users then should be able do
>> *               Find( ITK     Required     ITKCommon  ITKVtkGlue) *
>>    in their itk application code without specifying "Find(VTK .....)" in
>> their own code, unless their code depends on
>>    some other vtk modules  which are not specified in VtkGlue's
>> dependency list.
>>
>
> The main problem I see is the following case:
>
> I have ProjectA that only relies on ITK (without ITKVtkGlue). It has built
> for years with ITK built without ITKVtkGlue and using only:
>
> FIND_PACKAGE(ITK REQUIRED)
> INCLUDE(${USE_ITK_FILE})
>
> Then I have another project, ProjectB, that does need ITKVtkGlue. For this
> project, I have to compile ITK with ITKVtkGlue, and then additionally use:
>
> FIND_PACKAGE(VTK REQUIRED)
> INCLUDE(${USE_VTK_FILE})
>
> This is fine for ProjectB (though potentially confusing), but now ProjectA
> doesn't build against ITK anymore! And I have to go add:
>
> FIND_PACKAGE(VTK REQUIRED)
> INCLUDE(${USE_VTK_FILE})
>
> to ProjectA's CMakeLists.txt even though it doesn't require VTK at all
> (even via ITK)! The big problem comes when someone pulls my repository of
> ProjectA and they actually don't have VTK on their system at all. Why
> should they have to modify the CMakeLists.txt file just because they don't
> have a library that isn't required?
>
> David
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-developers
>
>


-- 
Unpaid intern in BillsBasement at noware dot com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-developers/attachments/20120703/d5570156/attachment.htm>


More information about the Insight-developers mailing list