[CMake] LINK_DIRECTORIES ?

motes motes mort.motes at gmail.com
Wed Aug 5 03:33:33 EDT 2009


I get the point of INCLUDE_DIRECTORIES (the various files used must be
located). But what is the point of LINK_DIRECTORIES and
TARGET_LINK_LIBRARIES? In a CMakeLists.txt file I have:



..
INCLUDE_DIRECTORIES(${ELASTIX_SRC}/Components/Optimizers/StandardGradientDescent)
...
...
LINK_DIRECTORIES(${ELASTIX_BUILD}/Components/Optimizers/StandardGradientDescent)
...
...
TARGET_LINK_LIBRARIES(test ITKCommon ITKAlgorithms ITKBasicFilters
ITKNumerics ITKIO ITKBasicFilters StandardGradientDescent elxCommon elxCore)




In the first line source files are located in the dir:
(${ELASTIX_SRC}/Components/Optimizers/StandardGradientDescent). But the same
dir is also used as a link library. In the last line various macros are used
in a target link library, but why is that necessary when the
LINK_DIRECTORIES are defined?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20090805/ee33efcd/attachment.htm>


More information about the CMake mailing list