ITK/Release 4/Modularization/Add a module/src/CMakeLists.txt: Difference between revisions

From KitwarePublic
Jump to navigationJump to search
No edit summary
No edit summary
Line 1: Line 1:
  set(ITK-Foo SRC
{{#tag:syntaxhighlight
|
set(ITK-Foo SRC
     itkFoo.cxx
     itkFoo.cxx
     )
     )
Line 6: Line 8:
   target_link_libraries(ITK-Foo  ${ITK-Foo_LIBRARIES}) # ${ITK-Foo_LIBRARIES} is defined in Foo/CMakeLists.txt
   target_link_libraries(ITK-Foo  ${ITK-Foo_LIBRARIES}) # ${ITK-Foo_LIBRARIES} is defined in Foo/CMakeLists.txt
   itk_module_target(ITK-Foo)  # itk_module_target() set up the rules for installation and target export of this module
   itk_module_target(ITK-Foo)  # itk_module_target() set up the rules for installation and target export of this module
|lang=cmake}}

Revision as of 15:23, 19 June 2011

<syntaxhighlight lang="cmake">

set(ITK-Foo SRC
    itkFoo.cxx
    )
  
 add_library(ITK-Foo ${ITK-Foo_SRC})
 target_link_libraries(ITK-Foo  ${ITK-Foo_LIBRARIES}) # ${ITK-Foo_LIBRARIES} is defined in Foo/CMakeLists.txt
 itk_module_target(ITK-Foo)  # itk_module_target() set up the rules for installation and target export of this module

</syntaxhighlight>