SET( _definitions BaseObjects Transforms BoundingBox Mesh ScalarImages ComplexImages ColorImages VectorImages MatrixImages Image ImageIterators ImageInterpolators NeighborhoodImageIterators BaseImageFilters ComplexImageFilters ImagesIO UnaryFunctorFilters BinaryFunctorFilters DistanceMapFilters ImageSliceFilters ImageSeparableFilters ExtractImageFilters ITKDifferenceImageFilters ITKAnisotropicSmoothing ITKLevelSetFilters ITKImageFeatureFilters PolyLineParametricPath Simple3DCurve Skeleton ) ## ======================= ## == Compile instances == ## ======================= SET(_all_libs) FOREACH(_d ${_definitions}) FILE(GLOB _files ${CMAKE_CURRENT_SOURCE_DIR}/${_d}.*) CreateLib(cpInstances${_d} SHARED ${_files}) TARGET_LINK_LIBRARIES( cpInstances${_d} ${ITK_LIBRARIES} ${VTK_LIBRARIES} ) LIST(APPEND _all_libs cpInstances${_d}) ENDFOREACH(_d) ## ===================== ## == Further linking == ## ===================== SET(_pfx cpInstances) TARGET_LINK_LIBRARIES(${_pfx}BoundingBox ${_pfx}BaseObjects cpPlugins) TARGET_LINK_LIBRARIES(${_pfx}Transforms ${_pfx}BaseObjects) TARGET_LINK_LIBRARIES(${_pfx}Mesh ${_pfx}BoundingBox) TARGET_LINK_LIBRARIES(${_pfx}ScalarImages ${_pfx}BaseObjects) TARGET_LINK_LIBRARIES(${_pfx}ComplexImages ${_pfx}ScalarImages) TARGET_LINK_LIBRARIES(${_pfx}ColorImages ${_pfx}ScalarImages) TARGET_LINK_LIBRARIES(${_pfx}VectorImages ${_pfx}ScalarImages) TARGET_LINK_LIBRARIES(${_pfx}MatrixImages ${_pfx}ScalarImages) TARGET_LINK_LIBRARIES( ${_pfx}Image ${_pfx}ScalarImages ${_pfx}ComplexImages ${_pfx}ColorImages ${_pfx}VectorImages ${_pfx}MatrixImages cpPlugins ) TARGET_LINK_LIBRARIES(${_pfx}ImageIterators ${_pfx}Image) TARGET_LINK_LIBRARIES(${_pfx}ImageInterpolators ${_pfx}Image) TARGET_LINK_LIBRARIES(${_pfx}NeighborhoodImageIterators ${_pfx}Image) TARGET_LINK_LIBRARIES(${_pfx}BaseImageFilters ${_pfx}ImageIterators) TARGET_LINK_LIBRARIES( ${_pfx}ComplexImageFilters ${_pfx}ImageIterators ${_pfx}NeighborhoodImageIterators ) TARGET_LINK_LIBRARIES( ${_pfx}ImagesIO ${_pfx}ScalarImages ${_pfx}ColorImages ${_pfx}VectorImages ${_pfx}Image ${_pfx}ImageIterators ${_pfx}BaseImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}UnaryFunctorFilters ${_pfx}Image ${_pfx}ImageIterators ${_pfx}BaseImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}BinaryFunctorFilters ${_pfx}Image ${_pfx}ImageIterators ${_pfx}BaseImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}DistanceMapFilters ${_pfx}UnaryFunctorFilters ${_pfx}Image ${_pfx}ImageIterators ${_pfx}NeighborhoodImageIterators ${_pfx}BaseImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}PolyLineParametricPath ${_pfx}BaseObjects cpPlugins ) TARGET_LINK_LIBRARIES( ${_pfx}Simple3DCurve cpExtensions cpPlugins ) TARGET_LINK_LIBRARIES( ${_pfx}Skeleton ${_pfx}PolyLineParametricPath ) TARGET_LINK_LIBRARIES( ${_pfx}ImageSliceFilters ${_pfx}Image ${_pfx}ImageIterators ${_pfx}NeighborhoodImageIterators ${_pfx}ImageInterpolators ${_pfx}BaseImageFilters ${_pfx}ComplexImageFilters ${_pfx}ExtractImageFilters ${_pfx}Transforms ${_pfx}Simple3DCurve ) TARGET_LINK_LIBRARIES( ${_pfx}ImageSeparableFilters ${_pfx}Image ${_pfx}BaseImageFilters ${_pfx}UnaryFunctorFilters ) TARGET_LINK_LIBRARIES( ${_pfx}ExtractImageFilters ${_pfx}Image ${_pfx}BaseImageFilters ${_pfx}ComplexImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}ITKImageFeatureFilters ${_pfx}Image ${_pfx}BaseImageFilters ${_pfx}ComplexImageFilters ${_pfx}NeighborhoodImageIterators ) TARGET_LINK_LIBRARIES( ${_pfx}ITKDifferenceImageFilters ${_pfx}Image ${_pfx}BaseImageFilters ${_pfx}ComplexImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}ITKAnisotropicSmoothing ${_pfx}ITKDifferenceImageFilters ) TARGET_LINK_LIBRARIES( ${_pfx}ITKLevelSetFilters ${_pfx}ITKAnisotropicSmoothing ${_pfx}Image ${_pfx}ImageIterators ${_pfx}NeighborhoodImageIterators ${_pfx}BaseImageFilters ${_pfx}ImageInterpolators ${_pfx}ExtractImageFilters ${_pfx}ITKImageFeatureFilters ) ## =================================================== ## == Keep track of all created instances libraries == ## =================================================== SET( cpPlugins_AllInstances ${_all_libs} CACHE INTERNAL "All valid instances." FORCE ) ## eof - $RCSfile$