Difference between revisions of "Documentation/4.1/Developers/Style Guide/CMake"
From Slicer Wiki
(Created page with '__TOC__ = Naming = # Macros/functions should be lower case and words separated with underscores #: <code>include_directories(${CMAKE_CURRENT_SOURCE_DIR}/Logic)</code> not <code>…') |
(Prepend documentation/versioncheck template. See http://na-mic.org/Mantis/view.php?id=2887) |
||
Line 1: | Line 1: | ||
+ | <noinclude>{{documentation/versioncheck}}</noinclude> | ||
__TOC__ | __TOC__ | ||
Latest revision as of 07:28, 14 June 2013
Home < Documentation < 4.1 < Developers < Style Guide < CMake
For the latest Slicer documentation, visit the read-the-docs. |
Contents
Naming
- Macros/functions should be lower case and words separated with underscores
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/Logic)
notINCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/Logic)
find_package(VTK REQUIRED)
notFIND_PACKAGE(VTK REQUIRED)
norFind_Package(VTK REQUIRED)
- Global variables are uppercase and words separated with underscores
CMAKE_CURRENT_SOURCE_DIR
notcmake_current_source_dir
- Local variables are lowercase and words separated with underscores
foreach(file ${FILES_TO_CONFIGURE})...
notforeach(FILE ${FILES_TO_CONFIGURE})...