-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
find_package(ITK 4.5 COMPONENT) corrupted by SEM #35
Comments
Matt, I think you may also be interested in knowing about this funny behavior when using recent SlicerExecutionModel checkouts. |
@jcfr I think this most recent patch in SlicerExecutionModel breaks behavior of find_package(ITK 4.5 COMPONENTS XXXX). The included CMakeLists.txt file demonstrates the bad behavior. When SEM is found first, and ITK found second, the incorrect (severely truncated include paths) is present. When SEM is second, then all seems to work OK. Hans |
@hjmjohnson Thanks for identifying the issue. Tracker here |
…er#35 Setting ITK_FOUND to FALSE after calling find_package(ITK COMPONENTS ${components}) will cause CMake to re-run the find_package process with a new set of COMPONENTS.
…er#35 Setting ITK_FOUND to FALSE after calling find_package(ITK COMPONENTS ${components}) will cause CMake to re-run the find_package process with a new set of COMPONENTS.
BUG: Allow projects to specify their own list of ITK COMPONENTS. #35
Associated issues: https://issues.itk.org/jira/browse/ITK-3294 Slicer/SlicerExecutionModel#35 Thanks to "Hans Johnson <hans-johnson@uiowa.edu>" for tracking down and identifying the problem and thanks to "Matt McCormick <matt.mccormick@kitware.com>" for submitting a fix. //--------------- $ git shortlog 4e61f6..feef59e --no-merges Matt McCormick (1): BUG: Allow projects to specify their own list of ITK COMPONENTS. #35 //--------------- git-svn-id: http://svn.slicer.org/Slicer4/trunk@23471 3bd1e089-480b-0410-8dfb-8563597acbee
Associated issues: https://issues.itk.org/jira/browse/ITK-3294 Slicer/SlicerExecutionModel#35 Thanks to "Hans Johnson <hans-johnson@uiowa.edu>" for tracking down and identifying the problem and thanks to "Matt McCormick <matt.mccormick@kitware.com>" for submitting a fix. //--------------- $ git shortlog 4e61f6..feef59e --no-merges Matt McCormick (1): BUG: Allow projects to specify their own list of ITK COMPONENTS. Slicer#35 //--------------- git-svn-id: http://svn.slicer.org/Slicer4/trunk@23471 3bd1e089-480b-0410-8dfb-8563597acbee
Assuming this is fixed. |
The CMakeLists.txt file below is a simple example that demonstrates that including SEM before ITK causes find_package(ITK COMPONENTS ) to be corrupted.
SlicerExecutionModel hash 865e2a7 does not seem to exhibit this behavior.
cmake_minimum_required(VERSION 3.0)
project(test)
set(ITK_IO_MODULES_USED "")
set(ITK_MODULES_USED
ITKAnisotropicSmoothing
ITKBinaryMathematicalMorphology
ITKCommon
ITKConnectedComponents
ITKCurvatureFlow
ITKDeprecated
ITKDiffusionTensorImage
ITKDisplacementField
ITKDistanceMap
ITKFFT
ITKFastMarching
ITKHDF5
ITKIOBMP
ITKIOBioRad
ITKIODCMTK
ITKIOGDCM
ITKIOGE
ITKIOGIPL
ITKIOImageBase
ITKIOJPEG
ITKIOLSM
ITKIOMeta
ITKIONIFTI
ITKIONRRD
ITKIOPNG
ITKIORAW
MGHIO
ITKIOSpatialObjects
ITKIOStimulate
ITKIOTIFF
ITKIOTransformBase
ITKIOXML
ITKImageAdaptors
ITKImageCompare
ITKImageCompose
ITKImageFeature
ITKImageFilterBase
ITKImageFunction
ITKImageFusion
ITKImageGradient
ITKImageGrid
ITKImageIntensity
ITKImageSources
ITKImageStatistics
ITKLabelMap
ITKLabelVoting
ITKLevelSets
ITKMathematicalMorphology
ITKMesh
ITKMetricsv4
ITKOptimizers
ITKOptimizersv4
ITKPDEDeformableRegistration
ITKQuadEdgeMesh
ITKQuadEdgeMeshFiltering
ITKRegionGrowing
ITKRegistrationCommon
ITKRegistrationMethodsv4
ITKReview
ITKSmoothing
ITKSpatialObjects
ITKStatistics
ITKTestKernel
ITKThresholding
ITKTransform
ITKV3Compatibility
${ITK_VTK_COMPONENTS}
${ITK_IO_MODULES_USED}
)
option(SEMFIRST "Include SEM First" ON)
if(SEMFIRST)
THIS FAILS
find_package(SlicerExecutionModel REQUIRED GenerateCLP)
include(${GenerateCLP_USE_FILE})
include(${SlicerExecutionModel_USE_FILE})
include(${SlicerExecutionModel_CMAKE_DIR}/SEMMacroBuildCLI.cmake)
message(STATUS "YYYY ${ITK_INCLUDE_DIRS}")
find_package(ITK 4.5 COMPONENTS
${ITK_MODULES_USED}
REQUIRED
)
include(${ITK_USE_FILE})
message(STATUS "XXXX ${ITK_INCLUDE_DIRS}")
else()
THIS WORKS
find_package(ITK 4.5 COMPONENTS
${ITK_MODULES_USED}
REQUIRED
)
include(${ITK_USE_FILE})
find_package(SlicerExecutionModel REQUIRED GenerateCLP)
include(${GenerateCLP_USE_FILE})
include(${SlicerExecutionModel_USE_FILE})
include(${SlicerExecutionModel_CMAKE_DIR}/SEMMacroBuildCLI.cmake)
message(STATUS "YYYY ${ITK_INCLUDE_DIRS}")
message(STATUS "XXXX ${ITK_INCLUDE_DIRS}")
endif()
The text was updated successfully, but these errors were encountered: