On 4/5/2012 9:14 AM, Bradley Lowekamp wrote: > When configuring a project to use ITK, it seems that I need to > add "lib/cmake" to the end of the install path to correctly
Don't you mean "lib/cmake/ITK-4.x"? > detect the installed ITK. This seems a bit awkward to me, and I > keep forgetting to do it. I am quite surprised that the cmake > find_package function doesn't do this. Is this the expected and > desired behavior? Yes, and find_package has always worked that way. There can be more than one copy/version of a given package under the same prefix. The ITK_DIR value must point to the exact location of ITKConfig.cmake, not just the install prefix. Otherwise it would be ITK_ROOT or ITK_PREFIX or something. If you know you have only one ITK under a given prefix then just put the prefix in CMAKE_PREFIX_PATH instead. Then find_package will dig into that to find lib/cmake/ITK-4.x automatically. -Brad K _______________________________________________ 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
