Medical Imaging Interaction Toolkit  2018.4.99-31d1c60d
Medical Imaging Interaction Toolkit
CMake Namespace Reference

Functions

 get_bundle_main_executable (bundle, result_var)
 
 get_dotapp_dir (exe, dotapp_dir_var)
 
 get_bundle_and_executable (app, bundle_var, executable_var, valid_var)
 
 get_bundle_all_executables (bundle, exes_var)
 
 get_item_rpaths (item, rpaths_var)
 
 get_item_key (item, key_var)
 
 clear_bundle_keys (keys_var)
 
 set_bundle_key_values (keys_var, context, item, exepath, dirs, copyflag)
 
 get_bundle_keys (app, libs, dirs, keys_var)
 
 link_resolved_item_into_bundle (resolved_item, resolved_embedded_item)
 
 copy_resolved_item_into_bundle (resolved_item, resolved_embedded_item)
 
 copy_resolved_framework_into_bundle (resolved_item, resolved_embedded_item)
 
 fixup_bundle_item (resolved_embedded_item, exepath, dirs)
 
 fixup_bundle (app, libs, dirs)
 
 copy_and_fixup_bundle (src, dst, libs, dirs)
 
 verify_bundle_prerequisites (bundle, result_var, info_var)
 
 verify_bundle_symlinks (bundle, result_var, info_var)
 
 verify_app (app)
 
 GIT_IS_REPO (dir, result_var)
 
 GIT_WC_INFO (dir, prefix)
 
 gp_append_unique (list_var, value)
 
 is_file_executable (file, result_var)
 
 gp_item_default_embedded_path (item, default_embedded_path_var)
 
 gp_resolve_item (context, item, exepath, dirs, resolved_item_var)
 
 gp_resolved_file_type (original_file, file, exepath, dirs, type_var)
 
 gp_file_type (original_file, file, type_var)
 
 get_prerequisites_clear_cache ()
 
 get_prerequisites (target, prerequisites_var, exclude_system, recurse, exepath, dirs)
 
 list_prerequisites (target)
 
 list_prerequisites_by_glob (glob_arg, glob_exp)
 
 MACRO_PARSE_ARGUMENTS (prefix, arg_names, option_names)
 
 func_build_target (target, build_dir)
 
 func_test (label, build_dir)
 
 finalize_submission ()
 
 check_for_errors ()
 
 run_ctest ()
 
 downloadFile (url, dest)
 
 mitkAddCustomModuleTest (test_name, test_function)
 Add a custom test for MITK module. More...
 
 mitkFunctionAddExternalProject ()
 
 mitkFunctionAddLibrarySearchPaths ()
 
 mitkFunctionAddTestLabel (test_name)
 
 mitkFunctionCheckCompilerFlags (CXX_FLAG_TO_TEST, RESULT_VAR)
 
 mitkFunctionCheckCAndCXXCompilerFlags (FLAG_TO_TEST, C_RESULT_VAR, CXX_RESULT_VAR)
 
 mitkFunctionCheckMitkCompatibility ()
 
 mitk_check_module_dependencies ()
 
 mitkFunctionCheckPackageHeader (_header, _provider)
 
 mitkFunctionCMakeDoxygenFilterCompile ()
 Download and compile a CMake doxygen input filter. More...
 
 mitkFunctionCompileSnippets (snippet_path)
 
 mitkFunctionConfigureVisualStudioUserProjectFile ()
 This function will configure a user file for visual studio projects. More...
 
 mitkFunctionConvertXPSchema ()
 
 mitkFunctionCreateBlueBerryApplication ()
 This function will create a BlueBerry application together with all necessary provisioning and configuration data and install support. More...
 
 FunctionCreateBlueBerryApplication ()
 
 mitkFunctionCreateCommandLineApp ()
 This function will create a command line executable and the scripts required to run it. More...
 
 mitkFunctionCreateMatchPointDeployedAlgorithm ()
 This function will create a command line executable and the scripts required to run it. More...
 
 mitk_create_module ()
 
 mitk_create_plugin ()
 Creates a MITK CTK plugin. More...
 
 _FUNCTION_CREATE_CTK_QT_COMPRESSED_HELP (qch_file, use_xsl)
 
 MACRO_CREATE_MITK_CTK_PLUGIN ()
 
 mitkFunctionCreateProvisioningFile ()
 Create a provisioning file. More...
 
 mitkFunctionCreateWindowsBatchScript (in, out, build_type)
 
 mitkFunctionEnableBuildConfiguration ()
 
 mitkFunctionGenerateProjectXml (dir, name, targets, is_superbuild)
 
 mitkFunctionGetGccVersion (path_to_gcc, output_var)
 Get the gcc version. More...
 
 mitkFunctionGetLibrarySearchPaths (search_path, intermediate_dir)
 
 mitkFunctionGetMSVCVersion ()
 
 mitkFunctionGetVersion (source_dir, prefix)
 Extract version information from a local working copy. More...
 
 mitkFunctionGetVersionDescription (source_dir, prefix)
 Extract the version description from a local working copy. More...
 
 mitkFunctionInstallAutoLoadModules ()
 Install auto-load modules needed by plug-ins. More...
 
 BlueBerryApplicationInstallHook ()
 
 mitkFunctionInstallCTKPlugin ()
 Install CTK plug-ins. More...
 
 mitkFunctionInstallExternalCMakeProject (ep_name)
 
 mitkFunctionInstallProvisioningFiles ()
 
 mitkFunctionInstallThirdPartyCTKPlugins ()
 Install external CTK plug-ins. More...
 
 mitkFunctionOrganizeSources ()
 
 _MACRO_APPEND_TO_LIST (_list, _value)
 
 SUPPRESS_VC_DEPRECATED_WARNINGS ()
 
 SUPPRESS_ALL_WARNINGS ()
 
 mitkFunctionTestPlugin ()
 
 MACRO_TEST_UIPLUGIN ()
 
 _mitk_parse_package_args ()
 
 _include_package_config (pkg_config_file)
 
 mitk_use_modules ()
 
 mitkFunctionCreateWhitelistPaths ()
 
 mitkFunctionFindWhitelists ()
 
 mitkFunctionWhitelistModules ()
 
 mitkFunctionWhitelistPlugins ()
 
 set_QUIET (var)
 
 _create_type_seq (TYPES, seq_var, seqdim_var)
 
 mitkMacroConfigureItkPixelTypes ()
 
 MITK_CREATE_DEFAULT_TESTS ()
 
 mitk_create_executable ()
 
 MITK_CREATE_MODULE_TESTS ()
 
 mitkMacroEmptyExternalProject (proj, dependencies)
 
 mitkMacroFindDependency (dep)
 
 MITK_GENERATE_TOOLS_LIBRARY ()
 
 GetLinuxDistribution ()
 
 mitkMacroGetPMDPlatformString (varname)
 
 MITK_INSTALL ()
 
 _fixup_target ()
 
 MITK_INSTALL_HELPER_APP ()
 
 MITK_INSTALL_TARGETS ()
 
 MITK_MULTIPLEX_PICTYPE (file)
 
 mitk_query_custom_ep_vars ()
 
 mitkSwigAddLibraryDependencies (swig_module, library_names)
 
 mitkSwigPrepareFiles (swig_module, swig_file, library_names)
 
 _get_target_type (result_var, target)
 
 _test_weak_link_project (target_type, lib_type, can_weak_link_var, project_name)
 
 mitk_check_dynamic_lookup ()
 
 _check_dynamic_lookup (target_type, lib_type, has_dynamic_lookup_var, link_flags_var)
 
 mitk_target_link_libraries_with_dynamic_lookup (target)
 
 CONFIGURE_PACKAGE_CONFIG_FILE (_inputFile, _outputFile)
 
 build_and_test ()
 
 create_initial_cache (var, _shared, _threading, _autoload)
 
 usFunctionAddResources ()
 Add resources to a library or executable. More...
 
 usFunctionCheckCompilerFlags (FLAG_TO_TEST, RESULT_VAR)
 
 usFunctionCheckResourceLinking ()
 
 usFunctionCompileSnippets (snippet_path)
 
 _us_create_test_module_helper ()
 
 usFunctionCreateTestModule (name)
 
 usFunctionCreateTestModuleWithResources (name)
 
 usFunctionEmbedResources ()
 Embed resources in a library or executable. More...
 
 usFunctionGenerateModuleInit (src_var)
 Generate a source file which handles proper initialization of a module. More...
 
 usFunctionGetGccVersion (path_to_gcc, output_var)
 Get the gcc version. More...
 
 usFunctionGetResourceSource ()
 Get a source file name for handling resource dependencies. More...
 
 usMacroCreateModule (_project_name)
 

Function Documentation

◆ _check_dynamic_lookup()

CMake::_check_dynamic_lookup ( target_type  ,
lib_type  ,
has_dynamic_lookup_var  ,
link_flags_var   
)

◆ _create_type_seq()

CMake::_create_type_seq ( TYPES  ,
seq_var  ,
seqdim_var   
)

◆ _fixup_target()

CMake::_fixup_target ( )

◆ _FUNCTION_CREATE_CTK_QT_COMPRESSED_HELP()

CMake::_FUNCTION_CREATE_CTK_QT_COMPRESSED_HELP ( qch_file  ,
use_xsl   
)

◆ _get_target_type()

CMake::_get_target_type ( result_var  ,
target   
)

◆ _include_package_config()

CMake::_include_package_config ( pkg_config_file  )

◆ _MACRO_APPEND_TO_LIST()

CMake::_MACRO_APPEND_TO_LIST ( _list  ,
_value   
)

◆ _mitk_parse_package_args()

CMake::_mitk_parse_package_args ( )

◆ _test_weak_link_project()

CMake::_test_weak_link_project ( target_type  ,
lib_type  ,
can_weak_link_var  ,
project_name   
)

◆ _us_create_test_module_helper()

CMake::_us_create_test_module_helper ( )

◆ BlueBerryApplicationInstallHook()

CMake::BlueBerryApplicationInstallHook ( )

◆ build_and_test()

CMake::build_and_test ( )

◆ check_for_errors()

CMake::check_for_errors ( )

◆ clear_bundle_keys()

CMake::clear_bundle_keys ( keys_var  )

◆ CONFIGURE_PACKAGE_CONFIG_FILE()

CMake::CONFIGURE_PACKAGE_CONFIG_FILE ( _inputFile  ,
_outputFile   
)

◆ copy_and_fixup_bundle()

CMake::copy_and_fixup_bundle ( src  ,
dst  ,
libs  ,
dirs   
)

◆ copy_resolved_framework_into_bundle()

CMake::copy_resolved_framework_into_bundle ( resolved_item  ,
resolved_embedded_item   
)

◆ copy_resolved_item_into_bundle()

CMake::copy_resolved_item_into_bundle ( resolved_item  ,
resolved_embedded_item   
)

◆ create_initial_cache()

CMake::create_initial_cache ( var  ,
_shared  ,
_threading  ,
_autoload   
)

◆ downloadFile()

CMake::downloadFile ( url  ,
dest   
)

◆ finalize_submission()

CMake::finalize_submission ( )

◆ fixup_bundle()

CMake::fixup_bundle ( app  ,
libs  ,
dirs   
)

◆ fixup_bundle_item()

CMake::fixup_bundle_item ( resolved_embedded_item  ,
exepath  ,
dirs   
)

◆ func_build_target()

CMake::func_build_target ( target  ,
build_dir   
)

◆ func_test()

CMake::func_test ( label  ,
build_dir   
)

◆ FunctionCreateBlueBerryApplication()

CMake::FunctionCreateBlueBerryApplication ( )

◆ get_bundle_all_executables()

CMake::get_bundle_all_executables ( bundle  ,
exes_var   
)

◆ get_bundle_and_executable()

CMake::get_bundle_and_executable ( app  ,
bundle_var  ,
executable_var  ,
valid_var   
)

◆ get_bundle_keys()

CMake::get_bundle_keys ( app  ,
libs  ,
dirs  ,
keys_var   
)

◆ get_bundle_main_executable()

CMake::get_bundle_main_executable ( bundle  ,
result_var   
)

◆ get_dotapp_dir()

CMake::get_dotapp_dir ( exe  ,
dotapp_dir_var   
)

◆ get_item_key()

CMake::get_item_key ( item  ,
key_var   
)

◆ get_item_rpaths()

CMake::get_item_rpaths ( item  ,
rpaths_var   
)

◆ get_prerequisites()

CMake::get_prerequisites ( target  ,
prerequisites_var  ,
exclude_system  ,
recurse  ,
exepath  ,
dirs   
)

◆ get_prerequisites_clear_cache()

CMake::get_prerequisites_clear_cache ( )

◆ GetLinuxDistribution()

CMake::GetLinuxDistribution ( )

◆ GIT_IS_REPO()

CMake::GIT_IS_REPO ( dir  ,
result_var   
)

◆ GIT_WC_INFO()

CMake::GIT_WC_INFO ( dir  ,
prefix   
)

◆ gp_append_unique()

CMake::gp_append_unique ( list_var  ,
value   
)

◆ gp_file_type()

CMake::gp_file_type ( original_file  ,
file  ,
type_var   
)

◆ gp_item_default_embedded_path()

CMake::gp_item_default_embedded_path ( item  ,
default_embedded_path_var   
)

◆ gp_resolve_item()

CMake::gp_resolve_item ( context  ,
item  ,
exepath  ,
dirs  ,
resolved_item_var   
)

◆ gp_resolved_file_type()

CMake::gp_resolved_file_type ( original_file  ,
file  ,
exepath  ,
dirs  ,
type_var   
)

◆ is_file_executable()

CMake::is_file_executable ( file  ,
result_var   
)

◆ link_resolved_item_into_bundle()

CMake::link_resolved_item_into_bundle ( resolved_item  ,
resolved_embedded_item   
)

◆ list_prerequisites()

CMake::list_prerequisites ( target  )

◆ list_prerequisites_by_glob()

CMake::list_prerequisites_by_glob ( glob_arg  ,
glob_exp   
)

◆ MACRO_CREATE_MITK_CTK_PLUGIN()

CMake::MACRO_CREATE_MITK_CTK_PLUGIN ( )

◆ MACRO_PARSE_ARGUMENTS()

CMake::MACRO_PARSE_ARGUMENTS ( prefix  ,
arg_names  ,
option_names   
)

◆ MACRO_TEST_UIPLUGIN()

CMake::MACRO_TEST_UIPLUGIN ( )

◆ mitk_check_dynamic_lookup()

CMake::mitk_check_dynamic_lookup ( )

◆ mitk_check_module_dependencies()

CMake::mitk_check_module_dependencies ( )

Checks if all required modules and packages exist and stores missing dependencies in <missing_deps>.

Usage:

mitk_check_module_dependencies( MODULES <module-list> PACKAGES <package-list> MISSING_DEPENDENCIES_VAR <missing_deps> MODULE_DEPENDENCIES_VAR <module_deps> PACKAGE_DEPENDENCIES_VAR <package_deps>)

◆ MITK_CREATE_DEFAULT_TESTS()

CMake::MITK_CREATE_DEFAULT_TESTS ( )

◆ mitk_create_executable()

CMake::mitk_create_executable ( )

Creates an executable with MITK dependencies and batch files for proper application start-up.

USAGE:

MITK_CREATE_EXECUTABLE( [<exectuableName>]
[DEPENDS <modules we need>]
[PACKAGE_DEPENDS <packages we need, like ITK, VTK, QT>]
[INCLUDE_DIRS <list of additional include directories>]
[TARGET_DEPENDS <list of additional dependencies>
[WARNINGS_NO_ERRORS]
Parameters
EXECUTABLE_NAMEThe name for the new executable target

◆ mitk_create_module()

CMake::mitk_create_module ( )

Creates a module for the automatic module dependency system within MITK.

Example:

DEPENDS PUBLIC MitkCore
PACKAGE_DEPENDS
PRIVATE Qt5|Xml+Networking
PUBLIC ITK|Watershed

The <moduleName> parameter specifies the name of the module which is used to create a logical target name. The parameter is optional in case the MITK_MODULE_NAME_DEFAULTS_TO_DIRECTORY_NAME variable evaluates to TRUE. The module name will then be derived from the directory name in which this function is called.

If set, the following variables will be used to validate the module name:

MITK_MODULE_NAME_REGEX_MATCH The module name must match this regular expression. MITK_MODULE_NAME_REGEX_NOT_MATCH The module name must not match this regular expression.

If the MITK_MODULE_NAME_PREFIX variable is set, the module name will be prefixed with its contents.

A modules source files are specified in a separate CMake file usually called files.cmake, located in the module root directory. The mitk_create_module() macro evaluates the following CMake variables from the files.cmake file:

  • CPP_FILES A list of .cpp files
  • H_FILES A list of .h files without a corresponding .cpp file
  • TXX_FILES A list of .txx files
  • RESOURCE_FILES A list of files (resources) which are embedded into the module
  • MOC_H_FILES A list of Qt header files which should be processed by the MOC
  • UI_FILES A list of .ui Qt UI files
  • QRC_FILES A list of .qrc Qt resource files
  • DOX_FILES A list of .dox Doxygen files

List of variables available after the function is called:

  • MODULE_NAME
  • MODULE_TARGET
  • MODULE_IS_ENABLED
  • MODULE_SUBPROJECTS
See also
mitk_create_executable

Parameters (all optional):

Parameters
<moduleName>The module name (also used as target name)
FILES_CMAKEFile name of a CMake file setting source list variables (defaults to files.cmake)
VERSIONModule version number, e.g. "1.2.0"
AUTOLOAD_WITHA module target name identifying the module which will trigger the automatic loading of this module
DEPRECATED_SINCEMarks this modules as deprecated since <arg>
DESCRIPTIONA description for this module

Multi-value Parameters (all optional):

Parameters
SUBPROJECTSList of CDash labels
INCLUDE_DIRSInclude directories for this module:
/// [[PUBLIC|PRIVATE|INTERFACE] <dir1>...]...
/// 
The default scope for include directories is PUBLIC.
DEPENDSList of module dependencies:
/// [[PUBLIC|PRIVATE|INTERFACE] <module1>...]...
/// 
The default scope for module dependencies is PUBLIC.
PACKAGE_DEPENDSList of public packages dependencies (e.g. Qt, VTK, etc.). Package dependencies have the following syntax:
/// [PUBLIC|PRIVATE|INTERFACE] PACKAGE[|COMPONENT1[+COMPONENT2]...]
/// 
The default scope for package dependencies is PRIVATE.
ADDITIONAL_LIBSList of additional private libraries linked to this module. The folder containing the library will be added to the global list of library search paths.
CPP_FILESList of source files for this module. If the list is non-empty, the module does not need to provide a files.cmake file or FILES_CMAKE argument.
H_FILESList of public header files for this module. It is recommended to use a files.cmake file instead.

Options (optional)

Parameters
FORCE_STATICForce building this module as a static library
GCC_DEFAULT_VISIBILITYDo not use gcc visibility flags - all symbols will be exported
NO_INITDo not create CppMicroServices initialization code
NO_FEATURE_INFODo not create a feature info by calling add_feature_info()
WARNINGS_NO_ERRORSDo not treat compiler warnings as errors

◆ MITK_CREATE_MODULE_TESTS()

CMake::MITK_CREATE_MODULE_TESTS ( )

◆ mitk_create_plugin()

CMake::mitk_create_plugin ( )

Creates a MITK CTK plugin.

This function should be called from the plugins CMakeLists.txt file. The target name is available after the macro call as ${PLUGIN_TARGET} to add additional libraries in your CMakeLists.txt. Include paths and link libraries are set depending on the value of the Required-Plugins header in your manifest_headers.cmake file.

This function internally calls ctkMacroBuildPlugin() and adds support for Qt Help files and installers.

Options:

Parameters
TEST_PLUGINMark this plug-in as a testing plug-in.
NO_INSTALLDon't install this plug-in.

Parameters:

Parameters
EXPORT_DIRECTIVE(required) The export directive to use in the generated <plugin_target>_Exports.h file.

Multi-value parameters (all optional):

Parameters
EXPORTED_INCLUDE_SUFFIXESA list of sub-directories which should be added to the current source directory. The resulting directories will be available in the set of include directories of depending plug-ins.
MODULE_DEPENDS(optional) A list of Modules this plug-in depends on.
PACKAGE_DEPENDS(optional) A list of external packages this plug-in depends on.
DOXYGEN_TAGFILES(optional) Which external tag files should be available for the plugin documentation
MOC_OPTIONS(optional) Additional options to pass to the Qt MOC compiler
WARNINGS_NO_ERRORS(optional) Do not handle compiler warnings as errors

◆ MITK_GENERATE_TOOLS_LIBRARY()

CMake::MITK_GENERATE_TOOLS_LIBRARY ( )

◆ MITK_INSTALL()

CMake::MITK_INSTALL ( )

◆ MITK_INSTALL_HELPER_APP()

CMake::MITK_INSTALL_HELPER_APP ( )

MITK specific cross plattform install macro

Usage: MITK_INSTALL_HELPER_APP(target1 [target2] ....)

◆ MITK_INSTALL_TARGETS()

CMake::MITK_INSTALL_TARGETS ( )

◆ MITK_MULTIPLEX_PICTYPE()

CMake::MITK_MULTIPLEX_PICTYPE ( file  )

◆ mitk_query_custom_ep_vars()

CMake::mitk_query_custom_ep_vars ( )

◆ mitk_target_link_libraries_with_dynamic_lookup()

CMake::mitk_target_link_libraries_with_dynamic_lookup ( target  )

◆ mitk_use_modules()

CMake::mitk_use_modules ( )

This CMake function sets up the necessary include directories, linker dependencies, and compile flags for a given target which depends on a set of MITK modules or packages.

A package argument is of the form

[PUBLIC|PRIVATE|INTERFACE] PACKAGE[|COMPONENT1[+COMPONENT2]...]

where PACKAGE is the package name (e.g. VTK) and components are the names of required package components or libraries.

If a dependency is not available, an error is thrown.

◆ mitkAddCustomModuleTest()

CMake::mitkAddCustomModuleTest ( test_name  ,
test_function   
)

Add a custom test for MITK module.

Parameters
test_nameUnique identifier for the test
test_functionName of the test function (the one with the argc,argv signature)

Additional parameters will be passed as command line parameters to the test.

◆ mitkFunctionAddExternalProject()

CMake::mitkFunctionAddExternalProject ( )

Register an external project.

Calling this function registers an external project with the MITK build system. Usage:

mitkFunctionAddExternalProject(NAME name [ON|OFF] [PACKAGE package] [COMPONENTS comp1...] [DEPENDS dep1...] [DOC docstring] [NO_CACHE] [ADVANCED] [NO_PACKAGE] )

The function creates a MITK_USE_<name> internal cache variable if the NO_CACHE option is given. If the NO_CACHE option is not set, a normal boolean cache option is created with the given DOC argument as help string. The option is marked as advanced if the ADVANCED option is set. The option's initial value matches the ON or OFF option and defaults to OFF if none is given. The DEPENDS arguments are used to force the corresponding MITK_USE_<depN> cache variables to ON if MITK_USE_<name> is ON.

The PACKAGE argument names the argument for the corresponding find_package() call in MITKs top-level CMakeLists.txt and MITKConfig.cmake file. It defaults to <name>. If COMPONENTS are specified, these are passed to the find_package() call. If the NO_PACKAGE option is given, the find_package() call is suppressed.

For each registered external project there must exist a file called CMakeExternals/<name>.cmake which defines the build process for the external project.

Note
Note that multiple calls of this function must be ordered relative to their declared dependencies. This applies to the DEPENDS arguments of this function as well as the actual target dependencies declared in the CMakeExternals/<name>.cmake file.

◆ mitkFunctionAddLibrarySearchPaths()

CMake::mitkFunctionAddLibrarySearchPaths ( )

Helper function that stores additional library search paths in order to use them in the mitkFunctionGetLibrarySearchPaths function.

Calling this function registers an external project with the MITK build system. Usage:

mitkFunctionAddLibrarySearchPaths(NAME name PATHS path1 [path2 ...] [DEBUG_PATHS path1 [path2 ...]] [MINSIZEREL_PATHS path1 [path2 ...]] [RELWITHDEBINFO_PATHS path1 [path2 ...]] )

The function adds the passed paths to a file stored in ${MITK_SUPERBUILD_BINARY_DIR}/MITK-AdditionalLibPaths. This information will be later on used by mitkFunctionGetLibrarySearchPaths. This allows external projects (also of extensions) to define library search paths that will be used in the superbuild. By using DEBUG_PATHS, MINSIZEREL_PATHS and RELWITHDEBINFO_PATHS, you can save special paths for debug, min size release or "release with debug info". If special paths are not explicitly specified, PATHS will be used for all configuration.

◆ mitkFunctionAddTestLabel()

CMake::mitkFunctionAddTestLabel ( test_name  )

◆ mitkFunctionCheckCAndCXXCompilerFlags()

CMake::mitkFunctionCheckCAndCXXCompilerFlags ( FLAG_TO_TEST  ,
C_RESULT_VAR  ,
CXX_RESULT_VAR   
)

◆ mitkFunctionCheckCompilerFlags()

CMake::mitkFunctionCheckCompilerFlags ( CXX_FLAG_TO_TEST  ,
RESULT_VAR   
)

◆ mitkFunctionCheckMitkCompatibility()

CMake::mitkFunctionCheckMitkCompatibility ( )

◆ mitkFunctionCheckPackageHeader()

CMake::mitkFunctionCheckPackageHeader ( _header  ,
_provider   
)

◆ mitkFunctionCMakeDoxygenFilterCompile()

CMake::mitkFunctionCMakeDoxygenFilterCompile ( )

Download and compile a CMake doxygen input filter.

Parameters
OUT<out-file> (optional) Supply an absolute filename for the generated executable.
NAMESPACE<namespace> (optional) Supply a C++ namespace in which the generated function declrarations should be wrapped.
Returns
This function sets the CMakeDoxygenFilter_EXECUTABLE variable to the absolute path of the generated input filter executable in the parent scope. If <out-file> is specified, they will be the same.

This CMake function compiles the http://github.com/saschazelzer/CMakeDoxygenFilter project into a doxygen input filter executable. See http://github.com/saschazelzer/CMakeDoxygenFilter/blob/master/README for more details.

◆ mitkFunctionCompileSnippets()

CMake::mitkFunctionCompileSnippets ( snippet_path  )

◆ mitkFunctionConfigureVisualStudioUserProjectFile()

CMake::mitkFunctionConfigureVisualStudioUserProjectFile ( )

This function will configure a user file for visual studio projects.

Configure user file for visual studio projects

Parameters
NAME(required) Name of the executable

◆ mitkFunctionConvertXPSchema()

CMake::mitkFunctionConvertXPSchema ( )

◆ mitkFunctionCreateBlueBerryApplication()

CMake::mitkFunctionCreateBlueBerryApplication ( )

This function will create a BlueBerry application together with all necessary provisioning and configuration data and install support.

Create a BlueBerry application.

Parameters
NAME(required) The name of the executable.
DESCRIPTION(optional) A human-readable description of your application. The usage depends on the CPack generator (on Windows, this is a descriptive text for the created shortcuts).
SOURCES(optional) A list of source files to compile into your executable. Defaults to <name>.cpp.
PLUGINS(optional) A list of required plug-ins. Defaults to all known plug-ins.
EXCLUDE_PLUGINS(optional) A list of plug-ins which should not be used. Mainly useful if PLUGINS was not used.
LINK_LIBRARIESA list of libraries to be linked with the executable.
LIBRARY_DIRSA list of directories to pass through to MITK_INSTALL_TARGETS
NO_PROVISIONING(option) Do not create provisioning files.
NO_INSTALL(option) Do not install this executable

Assuming that there exists a file called MyApp.cpp, an example call looks like:

NAME MyApp
DESCRIPTION "MyApp - New ways to explore medical data"
EXCLUDE_PLUGINS org.mitk.gui.qt.extapplication
)

◆ mitkFunctionCreateCommandLineApp()

CMake::mitkFunctionCreateCommandLineApp ( )

This function will create a command line executable and the scripts required to run it.

Create a Command Line App.

Parameters
NAME(required) Name of the command line app
DEPENDS(optional) Required MITK modules beyond MitkCommandLine
PACKAGE_DEPENDS(optional) list of "packages" this command line app depends on (e.g. ITK, VTK, etc.)
CPP_FILES(optional) list of cpp files, if it is not given NAME.cpp is assumed

Assuming that there exists a file called MyApp.cpp, an example call looks like:

NAME MyApp
DEPENDS MitkCore MitkPlanarFigure
PACKAGE_DEPENDS ITK VTK
)

◆ mitkFunctionCreateMatchPointDeployedAlgorithm()

CMake::mitkFunctionCreateMatchPointDeployedAlgorithm ( )

This function will create a command line executable and the scripts required to run it.

Create a Command Line App.

Parameters
NAME(required) Name of the algorithm / cmake target
DEPENDS(optional) Required MITK modules beyond MitkCommandLine
PACKAGE_DEPENDS(optional) list of "packages" this command line app depends on (e.g. ITK, VTK, etc.)
CPP_FILES(optional) list of cpp files, if it is not given NAME.cpp is assumed
INCLUDE_DIRS(optional): All directories that should be added as include dirs to the project
PROFILE(optional): The profile file that should be used for the algorithm. If not set it is "./<algname>.profile".
NO_PROFILE_GEN(optional): Flag. If set no profile resource will be generated.
ADDITIONAL_LIBS(optional) List of additional private libraries linked to this module. The folder containing the library will be added to the global list of library search paths.
H_FILES(optional) List of public header files for this module. Assuming that there exists a file called MyApp.cpp, an example call looks like:
NAME MyApp
DEPENDS MitkCore MitkPlanarFigure
PACKAGE_DEPENDS ITK VTK
)

◆ mitkFunctionCreateProvisioningFile()

CMake::mitkFunctionCreateProvisioningFile ( )

Create a provisioning file.

Parameters
FILE<provisioning-file> (required) An absolute filename for the new provisioning file.
INCLUDE<file-list> (optional) A list of additional provisioning files which should be included.
PLUGINS<plugin-list> (optional) A list of target names for which provisioning entries should be created. The entries must be valid targets or be of the form [subdir/]target_name:OFF (this is the same form as passed to the ctkMacroSetupPlugins macro) If the list is empty, all known plug-in targets (external or internal) are considered.
EXCLUDE_PLUGINS<plugin-list> (optional) A list of plug-in symbolic names which should be excluded from the provisioning entries.
NO_INSTALL(option) Suppress the creation of an additional provisioning file suitable for packaging.

This function creates a provisioning file which can be used to provision a BlueBerry application. The syntax of entries in the file is

(READ|INSTALL|START) <file-url>

READ includes the file at <file-url> and interprets it as a provisioning file, INSTALL installs <file-url>, and START installs and starts <file-url> as a plug-in in the framework.

For example the following provisioning file instructs the BlueBerry framework to read the entries in a file called SomeApp.provisioning and subsequently INSTALL and START the plug-in com.mycompany.plugin

READ file:
START file:///opt/mycompany/plugins/libcom_mycompany_plugin.so

An example invocation of this macro may look like:

set(_my_prov_file "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MyApp.provisioning")
set(_my_plugins
com.mycompany.plugin
org.mitk.gui.qt.extapplication
)
FunctionCreateProvisioningFile(FILE ${_my_prov_file} PLUGINS ${_my_plugins})
Note
This function will automatically create entries for all plug-in dependencies of the specified plug-ins.

◆ mitkFunctionCreateWhitelistPaths()

CMake::mitkFunctionCreateWhitelistPaths ( )

Creates advanced cache variables for setting the internal and external whitelist directories.

USAGE:

The <prefix> parameter specifies the prefix used for the created variables <prefix>_WHITELISTS_INTERNAL_PATH and <prefix>_WHITELISTS_EXTERNAL_PATH.

Default values: <prefix>_WHITELISTS_INTERNAL_PATH = <prefix>_SOURCE_DIR/CMake/Whitelists <prefix>_WHITELISTS_EXTERNAL_PATH = HOME%/.mitk/Whitelists

List of variables available after the function is called:

  • <prefix>_WHITELISTS_INTERNAL_PATH
  • <prefix>_WHITELISTS_EXTERNAL_PATH

Parameters:

Parameters
<prefix>The prefix of the created cache variables.

◆ mitkFunctionCreateWindowsBatchScript()

CMake::mitkFunctionCreateWindowsBatchScript ( in  ,
out  ,
build_type   
)

◆ mitkFunctionEnableBuildConfiguration()

CMake::mitkFunctionEnableBuildConfiguration ( )

◆ mitkFunctionFindWhitelists()

CMake::mitkFunctionFindWhitelists ( )

Adds all whitelists found in specfied whitelist paths to the advanced cache variable <prefix>_WHITELIST as enumeration entries.

USAGE:

The <prefix> parameter specifies the prefix used for the created cache variable <prefix>_WHITELIST. Its default value is "None". The function mitkFunctionCreateWhitelistPaths must be called with the same <prefix> prior to this function.

Whitelists are *.cmake files which set the two list variables enabled_modules and enabled_plugins.

List of variables available after the function is called:

  • <prefix>_WHITELIST
See also
mitkFunctionCreateWhitelistPaths

Parameters:

Parameters
<prefix>The prefix of the created cache variable.

◆ mitkFunctionGenerateProjectXml()

CMake::mitkFunctionGenerateProjectXml ( dir  ,
name  ,
targets  ,
is_superbuild   
)

◆ mitkFunctionGetGccVersion()

CMake::mitkFunctionGetGccVersion ( path_to_gcc  ,
output_var   
)

Get the gcc version.

◆ mitkFunctionGetLibrarySearchPaths()

CMake::mitkFunctionGetLibrarySearchPaths ( search_path  ,
intermediate_dir   
)

Helper function that gets all library search paths.

Usage:

mitkFunctionGetLibrarySearchPaths(search_path intermediate_dir [DEBUG|MINSIZEREL|RELWITHDEBINFO])

The function creates the variable ${search_path}. The variable intermediate_dir contains paths that should be added to the search_path but should not be checked for existance, because the are not yet created. The option DEBUG, MINSIZEREL or RELWITHDEBINFO can be used to indicate that not the paths for release configuration are requested but the debug, min size release or "release with debug info" paths.

◆ mitkFunctionGetMSVCVersion()

CMake::mitkFunctionGetMSVCVersion ( )

◆ mitkFunctionGetVersion()

CMake::mitkFunctionGetVersion ( source_dir  ,
prefix   
)

Extract version information from a local working copy.

If the source_dir variable points to a git repository, this function extracts the current revision hash and branch/tag name.

If the source_dir variable points to a subversion repository, this function extracts the current svn revision. The information is provided in

  • ${prefix}_REVISION_ID The git hash or svn revision value
  • ${prefix}_REVISION_NAME The git branch/tag name or empty
  • ${prefix}_WC_TYPE The working copy type, one of "local", "git", or "svn"
Parameters
source_dirThe directory containing a working copy
prefixA prefix to prepend to the variables containing the extracted information.

◆ mitkFunctionGetVersionDescription()

CMake::mitkFunctionGetVersionDescription ( source_dir  ,
prefix   
)

Extract the version description from a local working copy.

If the given repository is a git repository, the functions runs the git rev-parse –exact-match HEAD command

Information provided is stored in ${prefix}_REVISION_DESC an is

  • The exact tag if the HEAD of the source-tree has a tag
  • the 'git describe' output, which is <latest-reachable-tag>-<#Commits>-g<SHORT-HASH> In case the working copy contains local changes, the ${prefix}_REVISION_DESC strings will contain a suffix [local changes]
Parameters
source_dirThe directory containing a working copy
prefixA prefix to prepent to the variables containing the extracted information

◆ mitkFunctionInstallAutoLoadModules()

CMake::mitkFunctionInstallAutoLoadModules ( )

Install auto-load modules needed by plug-ins.

Uses the MITK_AUTOLOAD_TARGETS target property of the plug-in targets to extract a list of auto-load target names which will be installed in the given DESTINATION with an appropriate sub-directory appended. If an entry in TARGETS is not a known target, a warning will be issued. This macro can also work on imported plug-in targets.

Note
This macro is usually not called directly. It is indirectly called by a call to FunctionCreateBlueBerryApplication().
Parameters
PLUGINSA list of plug-in targets from which installable audo-load modules are derived.
DESTINATIONThe install destination, e.g. "bin".

◆ mitkFunctionInstallCTKPlugin()

CMake::mitkFunctionInstallCTKPlugin ( )

Install CTK plug-ins.

Installs the given list of CTK plug-in targets in the given DESTINATION. If an entry in TARGETS is not a known target, a warning will be issued. This macro can also install imported plug-in targets.

Note
This macro is usually not called directly. It is used in mitk_create_module() and mitkFunctionInstallThirdPartyCTKPlugins().
Parameters
TARGETS(optional) A list of plug-ins (target names) to install.
DESTINATION(optional) The install destination. Defaults to "bin/".

◆ mitkFunctionInstallExternalCMakeProject()

CMake::mitkFunctionInstallExternalCMakeProject ( ep_name  )

◆ mitkFunctionInstallProvisioningFiles()

CMake::mitkFunctionInstallProvisioningFiles ( )

◆ mitkFunctionInstallThirdPartyCTKPlugins()

CMake::mitkFunctionInstallThirdPartyCTKPlugins ( )

Install external CTK plug-ins.

Use this macro to call mitkFunctionInstallCTKPlugin() for all known or given external CTK plug-ins. The arguments given until a known argument name are treated as plug-in target names. If none are given, all known external plug-ins will be installed.

This macro supports multiple MacOSX Bundles by checking the variable MACOSX_BUNDLE_NAMES. If it exists, each plug-in will be installed in each given bundle (under <bundle_name>/Contents/MacOS/plugins), otherwise it will be installed in "bin/plugins".

Typical usage (will install all known external plug-ins):

FunctionInstallThirdPartyCTKPlugins()

To install only the org.commontk.eventadmin plug-in for example, call:

FunctionInstallThirdPartyCTKPlugins(org.commontk.eventadmin)
Note
If you provide specific plug-in names as arguments, you must make sure that your list includes the transitive closure of all plug-in dependencies. Use the ctkFunctionGetPluginDependencies() macro to obtain all dependencies of a specified set of plug-ins.

◆ mitkFunctionOrganizeSources()

CMake::mitkFunctionOrganizeSources ( )

◆ mitkFunctionTestPlugin()

CMake::mitkFunctionTestPlugin ( )

◆ mitkFunctionWhitelistModules()

CMake::mitkFunctionWhitelistModules ( )

Only enables modules which are present in the currently set whitelist or all modules if no whitelist is specified at all.

USAGE:

set(<modules>
ModuleDir
AnotherModuleDir
...
)
mitkFunctionWhitelistModules(<prefix> <modules>)

The <prefix> parameter specifies the prefix used to get the currently set whitelist from <prefix>_WHITELIST. Both functions mitkFunctionCreateWhitelistPaths and mitkFunctionFindWhitelists must be called with the same <prefix> prior to this function. The <modules> list must contain the module directory names instead of the module names itself, as the entries are used in add_directory calls.

See also
mitkFunctionCreateWhitelistPaths
mitkFunctionFindWhitelists

Parameters:

Parameters
<prefix>The prefix of the white list cache variable.
<modules>The module directory list variable.

◆ mitkFunctionWhitelistPlugins()

CMake::mitkFunctionWhitelistPlugins ( )

Only enables plugins which are present in the currently set whitelist or all plugins if no whitelist is specified at all.

USAGE:

set(<plugins>
org.example.plugin:OFF
org.example.another.plugin:ON
...
)
mitkFunctionWhitelistPlugins(<prefix> <plugins>)

The <prefix> parameter specifies the prefix used to get the currently set whitelist from <prefix>_WHITELIST. Both functions mitkFunctionCreateWhitelistPaths and mitkFunctionFindWhitelists must be called with the same <prefix> prior to this function. The <plugins> list must contain the plugin names. This function removes plugins not found in the currently set whitelist from the <plugins> variable. Note that plugins which are OFF by default are not switched on.

See also
mitkFunctionCreateWhitelistPaths
mitkFunctionFindWhitelists

Parameters:

Parameters
<prefix>The prefix of the white list cache variable.
<plugins>The plugin list variable to be modified.

◆ mitkMacroConfigureItkPixelTypes()

CMake::mitkMacroConfigureItkPixelTypes ( )

◆ mitkMacroEmptyExternalProject()

CMake::mitkMacroEmptyExternalProject ( proj  ,
dependencies   
)

◆ mitkMacroFindDependency()

CMake::mitkMacroFindDependency ( dep  )

Wraps a find_package call by forwarding QUIET and REQUIRED arguments from within the MITKConfig.cmake file.

mitkMacroFindDependency(<dep> [args])

◆ mitkMacroGetPMDPlatformString()

CMake::mitkMacroGetPMDPlatformString ( varname  )

◆ mitkSwigAddLibraryDependencies()

CMake::mitkSwigAddLibraryDependencies ( swig_module  ,
library_names   
)

This CMake macro adds the necessary library and incllude directories to a swig-project.

params: swig_module : Name of the SWIG module, for example pyMITK library_names : Semicolon separated list of the libraries that are included, for example "MitkCore;mbilog"

◆ mitkSwigPrepareFiles()

CMake::mitkSwigPrepareFiles ( swig_module  ,
swig_file  ,
library_names   
)

◆ run_ctest()

CMake::run_ctest ( )

◆ set_bundle_key_values()

CMake::set_bundle_key_values ( keys_var  ,
context  ,
item  ,
exepath  ,
dirs  ,
copyflag   
)

◆ set_QUIET()

CMake::set_QUIET ( var  )

◆ SUPPRESS_ALL_WARNINGS()

CMake::SUPPRESS_ALL_WARNINGS ( )

◆ SUPPRESS_VC_DEPRECATED_WARNINGS()

CMake::SUPPRESS_VC_DEPRECATED_WARNINGS ( )

◆ usFunctionCheckCompilerFlags()

CMake::usFunctionCheckCompilerFlags ( FLAG_TO_TEST  ,
RESULT_VAR   
)

◆ usFunctionCheckResourceLinking()

CMake::usFunctionCheckResourceLinking ( )

◆ usFunctionCompileSnippets()

CMake::usFunctionCompileSnippets ( snippet_path  )

◆ usFunctionCreateTestModule()

CMake::usFunctionCreateTestModule ( name  )

◆ usFunctionCreateTestModuleWithResources()

CMake::usFunctionCreateTestModuleWithResources ( name  )

◆ usFunctionGetGccVersion()

CMake::usFunctionGetGccVersion ( path_to_gcc  ,
output_var   
)

Get the gcc version.

◆ usMacroCreateModule()

CMake::usMacroCreateModule ( _project_name  )

◆ verify_app()

CMake::verify_app ( app  )

◆ verify_bundle_prerequisites()

CMake::verify_bundle_prerequisites ( bundle  ,
result_var  ,
info_var   
)

◆ verify_bundle_symlinks()

CMake::verify_bundle_symlinks ( bundle  ,
result_var  ,
info_var   
)