[Insight-users] CVS build problem: MetaIO

Gavin Baker gavinb+xtk at cs.mu.OZ.AU
Fri, 19 Mar 2004 18:11:23 +1100


Hello,

I found a small problem building ITK from CVS; a recent change in
Utilities/MetaIO/CMakeLists.txt has added:

  TARGET_LINK_LIBRARIES(ITKMetaIO itkzlib)

However this will not work when building using the system zlib libraries
(the normal thing to do on most *nix systems) since it hardcodes the
ITK-bundled version.

May I suggest the following small patch:


--- CMakeLists.txt.~1.15.~      Sat Mar 13 04:19:26 2004
+++ CMakeLists.txt              Fri Mar 19 18:05:29 2004
 at  at  -19,4 +19,4  at  at 
 
 INSTALL_TARGETS(/lib/InsightToolkit ITKMetaIO)
 INSTALL_FILES(/include/InsightToolkit/Utilities/MetaIO "(\\.h)$")
-TARGET_LINK_LIBRARIES(ITKMetaIO itkzlib)
+TARGET_LINK_LIBRARIES(ITKMetaIO ${ITK_ZLIB_LIBRARIES})


Thanks -

  :: Gavin

-- 
Gavin Baker                                      Complex Systems Group
http://www.cs.mu.oz.au/~gavinb             The University of Melbourne