Commit 752c2dff authored by jcfr's avatar jcfr

COMP: Move all MRML libraries into Libs/MRML sub-directory

* Also rename MRML library into MRMLCore library

git-svn-id: http://svn.slicer.org/Slicer4/trunk@18866 3bd1e089-480b-0410-8dfb-8563597acbee
parent f0482d52
......@@ -49,9 +49,9 @@ set(include_dirs
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
${Slicer_Base_INCLUDE_DIRS}
${MRML_INCLUDE_DIRS}
${MRMLCore_INCLUDE_DIRS}
${MRMLLogic_INCLUDE_DIRS}
${qMRMLWidgets_INCLUDE_DIRS}
${MRMLWidgets_INCLUDE_DIRS}
)
include_directories(${include_dirs})
......
......@@ -32,7 +32,7 @@
# include <ctkPythonConsole.h>
#endif
// qMRMLWidgets includes
// MRMLWidgets includes
#include <qMRMLEventLoggerWidget.h>
// SlicerQt includes
......
......@@ -16,7 +16,7 @@ add_subdirectory(Resources)
set(include_dirs
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_BINARY_DIR}
${MRML_INCLUDE_DIRS}
${MRMLCore_INCLUDE_DIRS}
${MRMLCLI_INCLUDE_DIRS}
${MRMLLogic_INCLUDE_DIRS}
${ModuleDescriptionParser_INCLUDE_DIRS}
......@@ -128,7 +128,7 @@ set(srcs ${SlicerBaseLogic_SRCS})
add_library(${lib_name} ${srcs})
set(libs
MRML
MRMLCore
MRMLCLI
MRMLLogic
vtkITK
......
......@@ -34,7 +34,7 @@ if(BUILD_TESTING)
SIMPLE_TEST( qSlicerCoreApplicationTest1)
set_property(TEST qSlicerCoreApplicationTest1 PROPERTY LABELS ${LIBRARY_NAME})
SIMPLE_TEST( qSlicerCoreIOManagerTest1 ${CMAKE_SOURCE_DIR}/Libs/MRML/Testing/name.mrml)
SIMPLE_TEST( qSlicerCoreIOManagerTest1 ${CMAKE_SOURCE_DIR}/Libs/MRML/Core/Testing/name.mrml)
set_property(TEST qSlicerCoreIOManagerTest1 PROPERTY LABELS ${LIBRARY_NAME})
SIMPLE_TEST( qSlicerAbstractCoreModuleTest1 )
SIMPLE_TEST( qSlicerLoadableModuleFactoryTest1 )
......
......@@ -204,7 +204,7 @@ endif()
# Resources
set(KIT_resources
Resources/qSlicerBaseQTGUI.qrc
${qMRMLWidgets_SOURCE_DIR}/Resources/qMRMLWidgets.qrc
${MRMLWidgets_SOURCE_DIR}/Resources/qMRMLWidgets.qrc
)
# Python wrap
......
......@@ -24,7 +24,7 @@
#include <QFileInfo>
#include <QVariant>
// qMRMLWidgets includes
// MRMLWidgets includes
#include <qMRMLSliceWidget.h>
#include <qMRMLSliceControllerWidget.h>
......
......@@ -24,7 +24,7 @@
// CTK includes
#include "qSlicerBaseQTGUIExport.h"
// qMRMLWidgets includes
// MRMLWidgets includes
#include <qMRMLLayoutManager.h>
class qSlicerLayoutManagerPrivate;
......
......@@ -668,7 +668,7 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS_INIT} ${Slicer_REQUIRED_CXX_FLAGS} ${ITK_
# Set the header template which defines custom export/import macros
# for shared libraries
#-----------------------------------------------------------------------------
set(QMRML_EXPORT_HEADER_TEMPLATE "${CMAKE_CURRENT_SOURCE_DIR}/Libs/qMRMLWidgets/CMake/qMRMLExport.h.in")
set(QMRML_EXPORT_HEADER_TEMPLATE "${CMAKE_CURRENT_SOURCE_DIR}/Libs/MRML/Widgets/CMake/qMRMLExport.h.in")
#-----------------------------------------------------------------------------
# Generate SlicerVersion.txt
......
......@@ -17,16 +17,16 @@ list(APPEND dirs
vtkTeem
vtkITK
FreeSurfer
MRML
MRMLCLI
MRML/Core
MRML/CLI
RemoteIO
MRMLLogic
MRMLDisplayableManager
MRMLIDImageIO
MRML/Logic
MRML/DisplayableManager
MRML/IDImageIO
MGHImageIO
IGT
#SIGN
qMRMLWidgets
MRML/Widgets
)
#-----------------------------------------------------------------------------
......@@ -64,18 +64,19 @@ set(IGT_USE_IGSTK ${Slicer_USE_IGSTK})
set(IGT_USE_NAVITRACK ${Slicer_USE_NAVITRACK})
# vtkITK contains tests that uses MRML's test data.
set(MRML_TEST_DATA_DIR ${CMAKE_CURRENT_SOURCE_DIR}/MRML/Testing/TestData)
set(MRML_TEST_DATA_DIR ${CMAKE_CURRENT_SOURCE_DIR}/MRML/Core/Testing/TestData)
#-----------------------------------------------------------------------------
# Loop over list of directories
#-----------------------------------------------------------------------------
foreach(dir ${dirs})
message(STATUS "Configuring library: ${dir}")
set(${dir}_INSTALL_BIN_DIR ${Slicer_INSTALL_LIB_DIR})
set(${dir}_INSTALL_LIB_DIR ${Slicer_INSTALL_LIB_DIR})
set(${dir}_INSTALL_SHARE_DIR ${Slicer_INSTALL_ROOT}share/${dir})
set(${dir}_INSTALL_NO_DEVELOPMENT ${Slicer_INSTALL_NO_DEVELOPMENT})
set(${dir}_EXPORT_FILE ${Slicer_BINARY_DIR}/SlicerTargets.cmake)
string(REPLACE "/" "" dir_noslash ${dir})
set(${dir_noslash}_INSTALL_BIN_DIR ${Slicer_INSTALL_LIB_DIR})
set(${dir_noslash}_INSTALL_LIB_DIR ${Slicer_INSTALL_LIB_DIR})
set(${dir_noslash}_INSTALL_SHARE_DIR ${Slicer_INSTALL_ROOT}share/${dir_noslash})
set(${dir_noslash}_INSTALL_NO_DEVELOPMENT ${Slicer_INSTALL_NO_DEVELOPMENT})
set(${dir_noslash}_EXPORT_FILE ${Slicer_BINARY_DIR}/SlicerTargets.cmake)
add_subdirectory(${dir})
endforeach()
......@@ -84,7 +85,8 @@ endforeach()
#-----------------------------------------------------------------------------
set(include_dirs)
foreach(dir ${dirs})
list(APPEND include_dirs ${${dir}_INCLUDE_DIRS})
string(REPLACE "/" "" dir_noslash ${dir})
list(APPEND include_dirs ${${dir_noslash}_INCLUDE_DIRS})
endforeach()
# Set variable Slicer_Libs_INCLUDE_DIRS
......@@ -97,7 +99,7 @@ set(Slicer_Libs_INCLUDE_DIRS ${include_dirs} CACHE INTERNAL "Slicer Libs include
# let's group these libraries.
# Note also that since MRMLIDImageIO is an ITK plugin it is NOT added to that list.
set(MRML_LIBRARIES
MRML MRMLCLI MRMLLogic MRMLDisplayableManager
MRMLCore MRMLCLI MRMLLogic MRMLDisplayableManager
CACHE INTERNAL "MRML libraries" FORCE)
#-----------------------------------------------------------------------------
......@@ -107,7 +109,7 @@ set(Slicer_Libs_VTK_WRAPPED_LIBRARIES
vtkTeem
vtkITK
FreeSurfer
MRML
MRMLCore
MRMLCLI
MRMLLogic
MRMLDisplayableManager
......
......@@ -30,7 +30,7 @@ endif()
set(include_dirs
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
${MRML_INCLUDE_DIRS}
${MRMLCore_INCLUDE_DIRS}
)
include_directories(${include_dirs})
......@@ -111,7 +111,7 @@ set(srcs ${IGT_SRCS})
add_library(${lib_name} ${srcs})
set(libs
MRML
MRMLCore
${TRACKING_INTERFACE_LIB}
)
......
......@@ -29,7 +29,7 @@ find_package(SlicerExecutionModel REQUIRED ModuleDescriptionParser)
set(include_dirs
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_BINARY_DIR}
${MRML_INCLUDE_DIRS}
${MRMLCore_INCLUDE_DIRS}
${ModuleDescriptionParser_INCLUDE_DIRS}
)
include_directories(${include_dirs})
......@@ -72,7 +72,7 @@ set(srcs ${MRMLCLI_SRCS})
add_library(${lib_name} ${srcs})
set(libs
MRML
MRMLCore
ModuleDescriptionParser
)
target_link_libraries(${lib_name} ${libs})
......@@ -113,7 +113,7 @@ if(VTK_WRAP_PYTHON)
vtkMacroKitPythonWrap(
KIT_NAME ${lib_name}
KIT_SRCS ${MRMLCLI_SRCS}
KIT_PYTHON_LIBRARIES MRMLPythonD
KIT_PYTHON_LIBRARIES MRMLCorePythonD
KIT_INSTALL_BIN_DIR ${${PROJECT_NAME}_INSTALL_BIN_DIR}
KIT_INSTALL_LIB_DIR ${${PROJECT_NAME}_INSTALL_LIB_DIR}
)
......
project(MRML)
project(MRMLCore)
#-----------------------------------------------------------------------------
cmake_minimum_required(VERSION 2.8.2)
......@@ -72,7 +72,7 @@ endif()
# --------------------------------------------------------------------------
# Sources
# --------------------------------------------------------------------------
set(MRML_SRCS
set(MRMLCore_SRCS
vtkEventBroker.cxx
vtkImageAccumulateDiscrete.cxx
vtkImageBimodalAnalysis.cxx
......@@ -171,8 +171,8 @@ set(MRML_SRCS
if(MRML_USE_Teem)
if(MRML_USE_vtkTeem)
set(MRML_SRCS
${MRML_SRCS}
set(MRMLCore_SRCS
${MRMLCore_SRCS}
vtkMRMLDiffusionImageVolumeNode.cxx
vtkMRMLDiffusionTensorVolumeDisplayNode.cxx
vtkMRMLDiffusionTensorVolumeNode.cxx
......@@ -196,8 +196,8 @@ set_source_files_properties(
ABSTRACT
)
string(REGEX REPLACE "\\.cxx" ".h" MRML_SRCS_HEADERS "${MRML_SRCS}")
source_group("Header Files" FILES ${MRML_SRCS_HEADERS})
string(REGEX REPLACE "\\.cxx" ".h" MRMLCore_SRCS_HEADERS "${MRMLCore_SRCS}")
source_group("Header Files" FILES ${MRMLCore_SRCS_HEADERS})
#-----------------------------------------------------------------------------
# Wrapping hints used by all Tcl, Python and Java wrapping.
......@@ -206,7 +206,7 @@ set(VTK_WRAP_HINTS ${CMAKE_CURRENT_SOURCE_DIR}/Wrapping/Tcl/hints)
# --------------------------------------------------------------------------
# Build library
# --------------------------------------------------------------------------
set(srcs ${MRML_SRCS} ${MRML_SRCS_HEADERS})
set(srcs ${MRMLCore_SRCS} ${MRMLCore_SRCS_HEADERS})
set(lib_name ${PROJECT_NAME})
add_library(${lib_name} ${srcs})
......@@ -257,7 +257,7 @@ install(TARGETS ${lib_name}
if(VTK_WRAP_PYTHON)
vtkMacroKitPythonWrap(
KIT_NAME ${lib_name}