Commit 3b987418 authored by andy's avatar andy

ENH: Move packaging into a subdirectory and start working on supporting tcl installing

git-svn-id: http://svn.slicer.org/Slicer4/trunk@1277 3bd1e089-480b-0410-8dfb-8563597acbee
parent d881ff19
......@@ -132,33 +132,10 @@ ENDIF (Slicer3_BUILD_TESTING)
INCLUDE (${CMAKE_ROOT}/Modules/TestBigEndian.cmake)
TEST_BIG_ENDIAN(CMAKE_WORDS_BIGENDIAN)
# If the cmake version includes cpack, use it
IF(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")
IF(EXISTS "${CMAKE_ROOT}/Modules/InstallRequiredSystemLibraries.cmake")
INCLUDE(InstallRequiredSystemLibraries)
ENDIF(EXISTS "${CMAKE_ROOT}/Modules/InstallRequiredSystemLibraries.cmake")
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Medical Visualization and Processing Environment for Research")
SET(CPACK_PACKAGE_VENDOR "NA-MIC")
SET(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README.txt")
SET(CPACK_PACKAGE_VERSION_MAJOR "${Slicer3_VERSION_MAJOR}")
SET(CPACK_PACKAGE_VERSION_MINOR "${Slicer3_VERSION_MINOR}")
SET(CPACK_PACKAGE_VERSION_PATCH "${Slicer3_VERSION_PATCH}")
SET(CPACK_INSTALL_CMAKE_PROJECTS
"${Slicer3_BINARY_DIR};Slicer3;ALL;/")
IF(EXISTS "${VTK_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${VTK_DIR};VTK;ALL;/")
ENDIF(EXISTS "${VTK_DIR}/CMakeCache.txt")
IF(EXISTS "${ITK_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ITK_DIR};ITK;ALL;/")
ENDIF(EXISTS "${ITK_DIR}/CMakeCache.txt")
IF(EXISTS "${KWWidgets_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${KWWidgets_DIR};KWWidgets;ALL;/")
ENDIF(EXISTS "${KWWidgets_DIR}/CMakeCache.txt")
SET(CPACK_PACKAGE_EXECUTABLES "Slicer3" "Slicer")
INCLUDE(CPack)
ENDIF(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")
# Package slicer
SUBDIRS(Utilities/Package)
# Documentation
OPTION(BUILD_DOCUMENTATION "Build Slicer3 Documentation" OFF)
IF(BUILD_DOCUMENTATION)
SUBDIRS(Utilities/Doxygen)
......
SET(CPACK_INSTALLED_DIRECTORIES)
SET(TCL_DIR "${Slicer3_BINARY_DIR}/../Slicer3-lib/tcl-build")
IF(EXISTS "${TCL_DIR}/bin/tclsh8.4" OR EXISTS "${TCL_DIR}/bin/tclsh84.exe")
ELSE(EXISTS "${TCL_DIR}/bin/tclsh8.4" OR EXISTS "${TCL_DIR}/bin/tclsh84.exe")
MESSAGE(STATUS "Not Packaging TCL (cannot found: ${TCL_DIR}/bin/tclsh8.4 or ${TCL_DIR}/bin/tclsh84.exe)")
SET(TCL_DIR "")
ENDIF(EXISTS "${TCL_DIR}/bin/tclsh8.4" OR EXISTS "${TCL_DIR}/bin/tclsh84.exe")
IF(TCL_DIR)
SET(CPACK_INSTALLED_DIRECTORIES ${CPACK_INSTALLED_DIRECTORIES}
"${TCL_DIR}" "/lib/Slicer3/tcl")
ENDIF(TCL_DIR)
CONFIGURE_FILE(
"${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt.in"
"${Slicer3_BINARY_DIR}/PackageLibraries/CMakeLists.txt"
@ONLY)
# If the cmake version includes cpack, use it
INCLUDE(InstallRequiredSystemLibraries)
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Medical Visualization and Processing Environment for Research")
SET(CPACK_PACKAGE_VENDOR "NA-MIC")
SET(CPACK_PACKAGE_DESCRIPTION_FILE "${Slicer3_SOURCE_DIR}/README.txt")
SET(CPACK_PACKAGE_VERSION_MAJOR "${Slicer3_VERSION_MAJOR}")
SET(CPACK_PACKAGE_VERSION_MINOR "${Slicer3_VERSION_MINOR}")
SET(CPACK_PACKAGE_VERSION_PATCH "${Slicer3_VERSION_PATCH}")
SET(CPACK_INSTALL_CMAKE_PROJECTS
"${Slicer3_BINARY_DIR};Slicer3;ALL;/")
IF(EXISTS "${VTK_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${VTK_DIR};VTK;ALL;/")
ENDIF(EXISTS "${VTK_DIR}/CMakeCache.txt")
IF(EXISTS "${ITK_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ITK_DIR};ITK;ALL;/")
ENDIF(EXISTS "${ITK_DIR}/CMakeCache.txt")
IF(EXISTS "${KWWidgets_DIR}/CMakeCache.txt")
SET(CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${KWWidgets_DIR};KWWidgets;ALL;/")
ENDIF(EXISTS "${KWWidgets_DIR}/CMakeCache.txt")
SET(CPACK_PACKAGE_EXECUTABLES "Slicer3" "Slicer")
INCLUDE(CPack)
PROJECT(InstallLibraries)
SET(TCL_DIR "@TCL_DIR@")
IF(TCL_DIR)
MESSAGE("Install Slicer3 Tcl")
ENDIF(TCL_DIR)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment