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

From KitwarePublic
Jump to navigationJump to search
No edit summary
No edit summary
Line 5: Line 5:




If this module generates a library or libraries (has a "src" subdirectory):
If this module generates a library (has a "src" subdirectory):
   project(ITK-Foo)
   project(ITK-Foo)
    
    
   set(ITK-Foo_LIBRARIES ITK-Foo)  
   set(ITK-Foo_LIBRARIES ITK-Foo) # need to specify the library names
   itk_module_impl()
   itk_module_impl()

Revision as of 20:26, 4 April 2011

If this module only contains template source codes (no "src" subdirectory):

project(ITK-Foo)
 
itk_module_impl() #itk_module_impl() takes care of the installation and export rule for the module ITK-Foo


If this module generates a library (has a "src" subdirectory):

 project(ITK-Foo)
 
 set(ITK-Foo_LIBRARIES ITK-Foo) # need to specify the library names
 itk_module_impl()