diff --git a/CMake/mitkMacroCreatePlugin.cmake b/CMake/mitkMacroCreatePlugin.cmake deleted file mode 100755 index 942855b30a..0000000000 --- a/CMake/mitkMacroCreatePlugin.cmake +++ /dev/null @@ -1,25 +0,0 @@ -MACRO(MACRO_CREATE_MITK_PLUGIN) - MITK_CHECK_MODULE(_MODULE_CHECK_RESULT Mitk ${ARGN}) - IF(NOT _MODULE_CHECK_RESULT) - MITK_USE_MODULE(Mitk ${ARGN}) - - LINK_DIRECTORIES(${ALL_LIBRARY_DIRS}) - INCLUDE_DIRECTORIES(${ALL_INCLUDE_DIRECTORIES}) - MACRO_CREATE_PLUGIN() - - TARGET_LINK_LIBRARIES(${PLUGIN_TARGET} ${ALL_LIBRARIES}) - IF(MITK_DEFAULT_SUBPROJECTS) - SET_PROPERTY(TARGET ${PLUGIN_TARGET} PROPERTY LABELS ${MITK_DEFAULT_SUBPROJECTS}) - FOREACH(subproject ${MITK_DEFAULT_SUBPROJECTS}) - ADD_DEPENDENCIES(${subproject} ${PLUGIN_TARGET}) - ENDFOREACH() - ENDIF() - ELSE(NOT _MODULE_CHECK_RESULT) - IF(NOT CURRENT_PLUGIN_BUILD_FORCED) - MESSAGE(SEND_ERROR "${BUNDLE-SYMBOLICNAME} is missing requirements and won't be built. Missing: ${_MODULE_CHECK_RESULT}") - ELSE() - MESSAGE(WARNING "${BUNDLE-SYMBOLICNAME} is missing requirements and won't be built. Missing: ${_MODULE_CHECK_RESULT}") - ENDIF() - ENDIF(NOT _MODULE_CHECK_RESULT) -ENDMACRO() - diff --git a/MITKConfig.cmake.in b/MITKConfig.cmake.in index c9e74fb5e5..fe7b6fe94b 100644 --- a/MITKConfig.cmake.in +++ b/MITKConfig.cmake.in @@ -1,150 +1,135 @@ # Update the CMake module path SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "@MITK_SOURCE_DIR@/CMake") # Include MITK macros include(MacroParseArguments) include(mitkFunctionOrganizeSources) include(mitkFunctionCreateWindowsBatchScript) include(mitkFunctionInstallProvisioningFiles) include(mitkMacroCreateModuleConf) include(mitkMacroCreateModule) include(mitkMacroCheckModule) include(mitkMacroCreateModuleTests) include(mitkFunctionAddCustomModuleTest) include(mitkMacroUseModule) include(mitkMacroMultiplexPicType) include(mitkMacroInstall) include(mitkMacroInstallHelperApp) include(mitkMacroInstallTargets) include(mitkMacroGenerateToolsLibrary) include(mitkMacroCreateCTKPlugin) # The MITK version number SET(MITK_VERSION_MAJOR "@MITK_VERSION_MAJOR@") SET(MITK_VERSION_MINOR "@MITK_VERSION_MINOR@") SET(MITK_VERSION_PATCH "@MITK_VERSION_PATCH@") SET(MITK_VERSION_STRING "@MITK_VERSION_STRING@") # MITK specific variables SET(MITK_SOURCE_DIR "@MITK_SOURCE_DIR@") SET(MITK_BINARY_DIR "@MITK_BINARY_DIR@") SET(UTILITIES_DIR "@UTILITIES_DIR@") SET(REGISTER_QFUNCTIONALITY_CPP_IN "@REGISTER_QFUNCTIONALITY_CPP_IN@") SET(MITK_MODULES_PACKAGE_DEPENDS_DIR "@MITK_MODULES_PACKAGE_DEPENDS_DIR@") SET(MODULES_PACKAGE_DEPENDS_DIRS "@MODULES_PACKAGE_DEPENDS_DIRS@") SET(MITK_DOXYGEN_TAGFILE_NAME "@MITK_DOXYGEN_TAGFILE_NAME@") IF(MODULES_CONF_DIRS) LIST(APPEND MODULES_CONF_DIRS "@MODULES_CONF_DIRS@") LIST(REMOVE_DUPLICATES MODULES_CONF_DIRS) ELSE() SET(MODULES_CONF_DIRS "@MODULES_CONF_DIRS@") ENDIF() SET(MODULES_CONF_DIRNAME "@MODULES_CONF_DIRNAME@") FOREACH(_module @MITK_MODULE_NAMES@) SET(${_module}_CONFIG_FILE "@MITK_BINARY_DIR@/@MODULES_CONF_DIRNAME@/${_module}Config.cmake") ENDFOREACH() # Include directory variables SET(MITK_INCLUDE_DIRS "@MITK_INCLUDE_DIRS@") SET(QMITK_INCLUDE_DIRS "@QMITK_INCLUDE_DIRS@") SET(ANN_INCLUDE_DIR "@ANN_INCLUDE_DIR@") SET(IPSEGMENTATION_INCLUDE_DIR "@IPSEGMENTATION_INCLUDE_DIR@") SET(VECMATH_INCLUDE_DIR "@VECMATH_INCLUDE_DIR@") SET(IPFUNC_INCLUDE_DIR "@IPFUNC_INCLUDE_DIR@") SET(MITK_IGT_INCLUDE_DIRS "@MITK_IGT_INCLUDE_DIRS@") # Library variables SET(MITK_LIBRARIES "@MITK_LIBRARIES@") SET(QMITK_LIBRARIES "@QMITK_LIBRARIES@") # Link directory variables SET(MITK_LINK_DIRECTORIES "@MITK_LINK_DIRECTORIES@") SET(QMITK_LINK_DIRECTORIES "@QMITK_LINK_DIRECTORIES@") SET(MITK_LIBRARY_DIRS "@CMAKE_LIBRARY_OUTPUT_DIRECTORY@" "@CMAKE_LIBRARY_OUTPUT_DIRECTORY@/plugins") SET(MITK_VTK_LIBRARY_DIRS "@MITK_VTK_LIBRARY_DIRS@") SET(MITK_ITK_LIBRARY_DIRS "@MITK_ITK_LIBRARY_DIRS@") # External projects SET(ITK_DIR "@ITK_DIR@") SET(VTK_DIR "@VTK_DIR@") SET(DCMTK_DIR "@DCMTK_DIR@") SET(GDCM_DIR "@GDCM_DIR@") SET(BOOST_ROOT "@BOOST_ROOT@") SET(OpenCV_DIR "@OpenCV_DIR@") SET(MITK_QMAKE_EXECUTABLE "@QT_QMAKE_EXECUTABLE@") SET(MITK_DATA_DIR "@MITK_DATA_DIR@") SET(MITK_RUNTIME_PATH "@MITK_RUNTIME_PATH@") # MITK use variables SET(MITK_USE_QT @MITK_USE_QT@) SET(MITK_USE_BLUEBERRY @MITK_USE_BLUEBERRY@) SET(MITK_USE_SYSTEM_Boost @MITK_USE_SYSTEM_Boost@) SET(MITK_USE_Boost @MITK_USE_Boost@) SET(MITK_USE_Boost_LIBRARIES @MITK_USE_Boost_LIBRARIES@) SET(MITK_USE_CTK @MITK_USE_CTK@) SET(MITK_USE_DCMTK @MITK_USE_DCMTK@) SET(MITK_USE_OpenCV @MITK_USE_OpenCV@) SET(MITK_USE_Python @MITK_USE_Python@) # There is no PocoConfig.cmake, so we set Poco specific CMake variables # here. This way the call to FIND_PACKAGE(Poco) in BlueBerryConfig.cmake # finds the Poco distribution supplied by MITK SET(Poco_INCLUDE_DIR "@MITK_SOURCE_DIR@/Utilities/Poco") SET(Poco_LIBRARY_DIR "@MITK_BINARY_DIR@/bin") IF(MITK_USE_IGT) #INCLUDE(${MITK_DIR}/mitkIGTConfig.cmake) ENDIF() IF(NOT MITK_EXPORTS_FILE_INCLUDED) IF(EXISTS "@MITK_EXPORTS_FILE@") SET(MITK_EXPORTS_FILE_INCLUDED 1) INCLUDE("@MITK_EXPORTS_FILE@") ENDIF(EXISTS "@MITK_EXPORTS_FILE@") ENDIF() # BlueBerry support IF(MITK_USE_BLUEBERRY) SET(BlueBerry_DIR "@MITK_BINARY_DIR@/BlueBerry") - - INCLUDE(mitkMacroCreatePlugin) - - IF(NOT MITK_SKIP_BUNDLELIST) - IF(MITK_USE_EXT) - INCLUDE("@MITK_BINARY_DIR@/Bundles/MITKModulesBundleList.cmake") - ENDIF() - ENDIF(NOT MITK_SKIP_BUNDLELIST) # Don't include the BlueBerry exports file, since the targets are # also exported in the MITK exports file SET(BB_PLUGIN_EXPORTS_FILE_INCLUDED 1) FIND_PACKAGE(BlueBerry) IF(NOT BlueBerry_FOUND) MESSAGE(SEND_ERROR "MITK does not seem to be configured with BlueBerry support. Set MITK_USE_BLUEBERRY to ON in your MITK build configuration.") ENDIF(NOT BlueBerry_FOUND) - SET(MITK_PLUGIN_SOURCE_DIRS "@MITK_SOURCE_DIR@/Bundles") - - SET(MITK_PLUGIN_OUTPUT_DIRS ) - IF(MITK_USE_EXT) - LIST(APPEND MITK_PLUGIN_OUTPUT_DIRS @MITK_MODULES_PLUGIN_OUTPUT_DIRS@) - ENDIF() - SET(MITK_PLUGIN_USE_FILE @MITK_PLUGIN_USE_FILE@) IF(MITK_PLUGIN_USE_FILE) IF(EXISTS ${MITK_PLUGIN_USE_FILE}) INCLUDE(${MITK_PLUGIN_USE_FILE}) ENDIF() ENDIF() SET(MITK_PLUGIN_PROVISIONING_FILE "@MITK_EXTAPP_PROVISIONING_FILE@") SET(MITK_PROVISIONING_FILES "${BLUEBERRY_PLUGIN_PROVISIONING_FILE}" "${MITK_PLUGIN_PROVISIONING_FILE}") ENDIF(MITK_USE_BLUEBERRY)