Commit 13cdfb49 authored by millerjv's avatar millerjv
Browse files

ENH: More configuration changes to support building plugins from a Slicer3...

ENH: More configuration changes to support building plugins from a Slicer3 installation (still not complete)

git-svn-id: http://svn.slicer.org/Slicer4/trunk@4929 3bd1e089-480b-0410-8dfb-8563597acbee
parent 98c4362e
......@@ -218,7 +218,7 @@ ENDIF(VTKsource_revision LESS 1.2196)
SET(GenerateCLP_DIR ${Slicer3_BINARY_DIR}/Libs/GenerateCLP)
SET(ModuleDescriptionParser_DIR ${Slicer3_BINARY_DIR}/Libs/ModuleDescriptionParser)
SET(vtkITK_DIR ${Slicer3_BINARY_DIR}/Libs/vtkITK)
SET(tclap_DIR ${Slicer3_BINARY_DIR}/Libs/tclap)
SET(TCLAP_DIR ${Slicer3_BINARY_DIR}/Libs/tclap)
#
......@@ -275,3 +275,22 @@ INSTALL(
FILES ${Slicer3_BINARY_DIR}/lib/launch.tcl
DESTINATION lib
)
# Set up for building against a Slicer3 build tree and a Slicer3 installation
#
#
INCLUDE( ${Slicer3_SOURCE_DIR}/GenerateSlicer3Config.cmake)
CONFIGURE_FILE(${Slicer3_SOURCE_DIR}/UseSlicer3.cmake.in
${Slicer3_BINARY_DIR}/UseSlicer3.cmake COPYONLY IMMEDIATE)
INSTALL(FILES
# ${Slicer3_BINARY_DIR}/Slicer3BuildSettings.cmake
${Slicer3_BINARY_DIR}/UseSlicer3.cmake
${Slicer3_BINARY_DIR}/Utilities/Slicer3Config.cmake
DESTINATION lib
COMPONENT Development
)
# Generate the Slicer3Config.cmake file in the build tree and configure one
# for the installation tree. This file tells external project how to use
# Slicer. This provides a mechanism for third party developers to build
# modules against a Slicer installation.
#
# Settings that are the same for build trees and installation trees
#
#
# Settings specific to build trees
#
#
SET(Slicer3_USE_FILE_CONFIG ${Slicer3_BINARY_DIR}/UseSlicer3.cmake)
SET(TCLAP_DIR_CONFIG ${Slicer3_BINARY_DIR}/Libs/tclap)
SET(ModuleDescriptionParser_DIR_CONFIG ${Slicer3_BINARY_DIR}/Libs/ModuleDescriptionParser)
SET(GenerateCLP_DIR_CONFIG ${Slicer3_BINARY_DIR}/Libs/GenerateCLP)
SET(GenerateCLP_USE_FILE_CONFIG ${Slicer3_SOURCE_DIR}/Libs/GenerateCLP/UseGenerateCLP.cmake)
SET(Slicer3_INCLUDE_DIRS_CONFIG ${Slicer3_SOURCE_DIR}/Applications/CLI)
SET(Slicer3_LIBRARY_DIRS_CONFIG ${Slicer3_BINARY_DIR}/bin)
# Configure Slicer3Config.cmake for the install tree.
CONFIGURE_FILE(${Slicer3_SOURCE_DIR}/Slicer3Config.cmake.in
${Slicer3_BINARY_DIR}/Slicer3Config.cmake @ONLY IMMEDIATE)
# Settings specific for installation trees
#
#
SET(Slicer3_USE_FILE_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/UseSlicer3.cmake)
SET(TCLAP_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/tclap)
SET(ModuleDescriptionParser_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/ModuleDescriptionParser)
SET(GenerateCLP_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/GenerateCLP)
SET(GenerateCLP_USE_FILE_CONFIG ${CMAKE_INSTALL_PREFIX}/Libs/GenerateCLP/UseGenerateCLP.cmake)
SET(Slicer3_INCLUDE_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/Slicer3/)
SET(Slicer3_LIBRARY_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/bin)
# Configure Slicer3Config.cmake for the install tree.
CONFIGURE_FILE(${Slicer3_SOURCE_DIR}/Slicer3Config.cmake.in
${Slicer3_BINARY_DIR}/Utilities/Slicer3Config.cmake @ONLY IMMEDIATE)
......@@ -3,20 +3,33 @@ PROJECT(GenerateCLP)
CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
FIND_PACKAGE(ModuleDescriptionParser REQUIRED)
FIND_PACKAGE(ITK REQUIRED)
IF(ModuleDescriptionParser_FOUND)
INCLUDE(${ModuleDescriptionParser_USE_FILE})
ENDIF(ModuleDescriptionParser_FOUND)
FIND_PACKAGE(TCLAP REQUIRED)
IF(TCLAP_FOUND)
INCLUDE(${TCLAP_USE_FILE})
ENDIF(TCLAP_FOUND)
LINK_DIRECTORIES(${ModuleDescriptionParser_BINARY_DIR})
FIND_PACKAGE(ITK REQUIRED)
IF(ITK_FOUND)
INCLUDE(${ITK_USE_FILE})
ENDIF(ITK_FOUND)
INCLUDE(${ITK_USE_FILE})
INCLUDE(UseGenerateCLP.cmake)
CONFIGURE_FILE(
${GenerateCLP_SOURCE_DIR}/GenerateCLPConfig.cmake.in
${GenerateCLP_BINARY_DIR}/GenerateCLPConfig.cmake
)
INCLUDE(GenerateGenerateCLPConfig.cmake)
# If we followed the standard pattern, UseGenerateCLP.cmake would be
# a configured file
#
#CONFIGURE_FILE(${GenerateCLP_SOURCE_DIR}/UseGenerateCLP.cmake.in
# ${GenerateCLP_BINARY_DIR}/UseGenerateCLP.cmake
# COPYONLY IMMEDIATE)
SET (GENERATECLP_SOURCE GenerateCLP.cxx)
LINK_DIRECTORIES(${ModuleDescriptionParser_LIB_DIR})
ADD_EXECUTABLE ( GenerateCLP ${GENERATECLP_SOURCE})
TARGET_LINK_LIBRARIES ( GenerateCLP
ModuleDescriptionParser
......@@ -28,3 +41,7 @@ IF(BUILD_TESTING)
ENDIF(BUILD_TESTING)
INSTALL(TARGETS GenerateCLP RUNTIME DESTINATION bin COMPONENT Development)
INSTALL(FILES ${GenerateCLP_SOURCE_DIR}/UseGenerateCLP.cmake
${GenerateCLP_BINARY_DIR}/install/GenerateCLPConfig.cmake
DESTINATION lib/GenerateCLP
COMPONENT Development)
# The GenerateCLP source tree.
SET(GenerateCLP_SOURCE_DIR "@GenerateCLP_SOURCE_DIR@")
SET(GenerateCLP_BINARY_DIR "@GenerateCLP_BINARY_DIR@")
SET(TCLAP_DIR "@TCLAP_DIR@")
SET(GENERATECLP_EXE "@GENERATECLP_EXE@")
SET(ModuleDescriptionParser_DIR "@ModuleDescriptionParser_BINARY_DIR@")
SET(ITK_DIR "@ITK_DIR@")
SET(GenerateCLP_INCLUDE_DIRS "@GenerateCLP_INCLUDE_DIRS_CONFIG@")
SET(GenerateCLP_LIBRARY_DIRS "@GenerateCLP_LIBRARY_DIRS_CONFIG@")
SET(GenerateCLP_USE_FILE "@GenerateCLP_USE_FILE_CONFIG@")
SET(GENERATECLP_EXE "@GENERATECLP_EXE_CONFIG@")
SET(TCLAP_DIR "@TCLAP_DIR_CONFIG@")
SET(ModuleDescriptionParser_DIR "@ModuleDescriptionParser_DIR_CONFIG@")
SET(ITK_DIR "@ITK_DIR_CONFIG@")
# Generate the GenerateCLPConfig.cmake file in the build tree and configure
# one the installation tree.
# Settings specific to build trees
#
#
SET(GenerateCLP_INCLUDE_DIRS_CONFIG ${GenerateCLP_BINARY_DIR} ${GenerateCLP_SOURCE_DIR})
SET(GenerateCLP_LIBRARY_DIRS_CONFIG ${GenerateCLP_BINARY_DIR})
SET(GenerateCLP_USE_FILE_CONFIG ${GenerateCLP_SOURCE_DIR}/UseGenerateCLP.cmake)
SET(GENERATECLP_EXE_CONFIG ${GENERATECLP_EXE})
SET(TCLAP_DIR_CONFIG ${TCLAP_DIR})
SET(ModuleDescriptionParser_DIR_CONFIG ${ModuleDescriptionParser_DIR})
SET(ITK_DIR_CONFIG ${ITK_DIR})
# Configure GenerateCLPConfig.cmake for the install tree.
CONFIGURE_FILE(${GenerateCLP_SOURCE_DIR}/GenerateCLPConfig.cmake.in
${GenerateCLP_BINARY_DIR}/GenerateCLPConfig.cmake @ONLY IMMEDIATE)
# Settings specific for installation trees
#
#
SET(GenerateCLP_INCLUDE_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/include/GenerateCLP)
SET(GenerateCLP_LIBRARY_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/GenerateCLP)
SET(GenerateCLP_USE_FILE_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/GenerateCLP/UseGenerateCLP.cmake)
SET(GENERATECLP_EXE_CONFIG ${CMAKE_INSTALL_PREFIX}/bin/GenerateCLP)
SET(TCLAP_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/tclap)
SET(ModuleDescriptionParser_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/ModuleDescriptionParser)
SET(ITK_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/InsightToolkit)
# Configure GenerateCLPConfig.cmake for the install tree.
CONFIGURE_FILE(${GenerateCLP_SOURCE_DIR}/GenerateCLPConfig.cmake.in
${GenerateCLP_BINARY_DIR}/install/GenerateCLPConfig.cmake @ONLY IMMEDIATE)
......@@ -13,20 +13,27 @@ IF(Slicer3_SOURCE_DIR)
ENDIF(Slicer3_SOURCE_DIR)
FIND_PACKAGE(TCLAP REQUIRED)
FIND_PACKAGE(ModuleDescriptionParser REQUIRED)
IF(TCLAP_FOUND)
INCLUDE(${TCLAP_USE_FILE})
ENDIF(TCLAP_FOUND)
INCLUDE_DIRECTORIES (${TCLAP_SOURCE_DIR}/include)
FIND_PACKAGE(ModuleDescriptionParser REQUIRED)
IF(ModuleDescriptionParser_FOUND)
INCLUDE(${ModuleDescriptionParser_USE_FILE})
ENDIF(ModuleDescriptionParser_FOUND)
IF(ModuleDescriptionParser_SOURCE_DIR)
INCLUDE_DIRECTORIES(
${ModuleDescriptionParser_SOURCE_DIR}
${ModuleDescriptionParser_BINARY_DIR}
)
ELSE(ModuleDescriptionParser_SOURCE_DIR)
INCLUDE_DIRECTORIES(
${Slicer3_SOURCE_DIR}/Libs/ModuleDescriptionParser
)
ENDIF(ModuleDescriptionParser_SOURCE_DIR)
#INCLUDE_DIRECTORIES (${TCLAP_SOURCE_DIR}/include)
#
#IF(ModuleDescriptionParser_SOURCE_DIR)
# INCLUDE_DIRECTORIES(
# ${ModuleDescriptionParser_SOURCE_DIR}
# ${ModuleDescriptionParser_BINARY_DIR}
# )
#ELSE(ModuleDescriptionParser_SOURCE_DIR)
# INCLUDE_DIRECTORIES(
# ${Slicer3_SOURCE_DIR}/Libs/ModuleDescriptionParser
# )
#ENDIF(ModuleDescriptionParser_SOURCE_DIR)
UTILITY_SOURCE(GENERATECLP_EXE GenerateCLP ./ GenerateCLP.cxx)
IF (NOT GENERATECLP_EXE)
......
......@@ -7,11 +7,6 @@ CONFIGURE_FILE(
${ModuleDescriptionParser_BINARY_DIR}/ModuleDescriptionParserConfigure.h
)
CONFIGURE_FILE(
${ModuleDescriptionParser_SOURCE_DIR}/ModuleDescriptionParserConfig.cmake.in
${ModuleDescriptionParser_BINARY_DIR}/ModuleDescriptionParserConfig.cmake
)
## ITK is required for expat.h
FIND_PACKAGE(ITK REQUIRED)
INCLUDE(${ITK_USE_FILE})
......@@ -61,8 +56,8 @@ ENDIF (USE_BFD)
INCLUDE_DIRECTORIES(
${ModuleDescriptionParser_SOURCE_DIR}
${ModuleDescriptionParser_BINARY_DIR}
${ModuleDescriptionParser_SOURCE_DIR}
)
IF(USE_PYTHON)
......@@ -107,6 +102,13 @@ IF(BUILD_TESTING)
SUBDIRS(Testing)
ENDIF(BUILD_TESTING)
INCLUDE (GenerateModuleDescriptionParserConfig.cmake)
CONFIGURE_FILE(${ModuleDescriptionParser_SOURCE_DIR}/UseModuleDescriptionParser.cmake.in
${ModuleDescriptionParser_BINARY_DIR}/UseModuleDescriptionParser.cmake COPYONLY IMMEDIATE)
INSTALL(TARGETS ModuleDescriptionParser
RUNTIME DESTINATION bin COMPONENT RuntimeLibraries
LIBRARY DESTINATION lib COMPONENT RuntimeLibraries
......@@ -115,3 +117,8 @@ INSTALL(TARGETS ModuleDescriptionParser
FILE(GLOB __files1 "${ModuleDescriptionParser_SOURCE_DIR}/*.h")
INSTALL(FILES ${__files1} DESTINATION include/ModuleDescriptionParser COMPONENT Development)
INSTALL(FILES ${ModuleDescriptionParser_BINARY_DIR}/ModuleDescriptionParserConfigure.h DESTINATION include/ModuleDescriptionParser COMPONENT Development)
INSTALL(FILES
${ModuleDescriptionParser_BINARY_DIR}/UseModuleDescriptionParser.cmake
${ModuleDescriptionParser_BINARY_DIR}/install/ModuleDescriptionParserConfig.cmake
DESTINATION lib/ModuleDescriptionParser COMPONENT Development)
# Generate the ModuleDescriptionParserConfig.cmake file in the build tree
# and configure one the installation tree.
# Settings specific to build trees
#
#
SET(ModuleDescriptionParser_INCLUDE_DIRS_CONFIG ${ModuleDescriptionParser_BINARY_DIR} ${ModuleDescriptionParser_SOURCE_DIR})
SET(ModuleDescriptionParser_LIBRARY_DIRS_CONFIG ${ModuleDescriptionParser_BINARY_DIR})
SET(ModuleDescriptionParser_USE_FILE_CONFIG ${ModuleDescriptionParser_BINARY_DIR}/UseModuleDescriptionParser.cmake)
SET(ITK_DIR_CONFIG ${ITK_DIR})
# Configure ModuleDescriptionParserConfig.cmake for the install tree.
CONFIGURE_FILE(${ModuleDescriptionParser_SOURCE_DIR}/ModuleDescriptionParserConfig.cmake.in
${ModuleDescriptionParser_BINARY_DIR}/ModuleDescriptionParserConfig.cmake @ONLY IMMEDIATE)
# Settings specific for installation trees
#
#
SET(ModuleDescriptionParser_INCLUDE_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/include/ModuleDescriptionParser)
SET(ModuleDescriptionParser_LIBRARY_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/ModuleDescriptionParser)
SET(ModuleDescriptionParser_USE_FILE_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/ModuleDescriptionParser/UseModuleDescriptionParser.cmake)
SET(ITK_DIR_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/InsightToolkit)
# Configure ModuleDescriptionParserConfig.cmake for the install tree.
CONFIGURE_FILE(${ModuleDescriptionParser_SOURCE_DIR}/ModuleDescriptionParserConfig.cmake.in
${ModuleDescriptionParser_BINARY_DIR}/install/ModuleDescriptionParserConfig.cmake @ONLY IMMEDIATE)
# The ModuleDescriptionParser source and binary trees. Also, the library direcory.
SET(ModuleDescriptionParser_SOURCE_DIR "@ModuleDescriptionParser_SOURCE_DIR@")
SET(ModuleDescriptionParser_BINARY_DIR "@ModuleDescriptionParser_BINARY_DIR@")
SET(ModuleDescriptionParser_LIB_DIR "@CMAKE_BINARY_DIR@/bin" "@CMAKE_BINARY_DIR@")
SET(ITK_DIR "@ITK_DIR@")
#
SET(ModuleDescriptionParser_INCLUDE_DIRS "@ModuleDescriptionParser_INCLUDE_DIRS_CONFIG@")
SET(ModuleDescriptionParser_LIBRARY_DIRS "@ModuleDescriptionParser_LIBRARY_DIRS_CONFIG@")
SET(ModuleDescriptionParser_USE_FILE "@ModuleDescriptionParser_USE_FILE_CONFIG@")
SET(ITK_DIR "@ITK_DIR_CONFIG@")
INCLUDE_DIRECTORIES(BEFORE ${ModuleDescriptionParser_INCLUDE_DIRS})
LINK_DIRECTORIES(${ModuleDescriptionParser_LIBRARY_DIRS})
......@@ -2,12 +2,18 @@ PROJECT(TCLAP)
CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
CONFIGURE_FILE(
${TCLAP_SOURCE_DIR}/TCLAPConfig.cmake.in
${TCLAP_BINARY_DIR}/TCLAPConfig.cmake
)
INCLUDE (GenerateTCLAPConfig.cmake)
CONFIGURE_FILE(${TCLAP_SOURCE_DIR}/UseTCLAP.cmake.in
${TCLAP_BINARY_DIR}/UseTCLAP.cmake COPYONLY IMMEDIATE)
FILE(GLOB __files1 "${TCLAP_SOURCE_DIR}/include/tclap/*.h")
INSTALL(FILES ${__files1} DESTINATION include/tclap COMPONENT Development)
# Note "COPYING" is a filename containing the license file
INSTALL(FILES COPYING DESTINATION include/tclap COMPONENT Development)
INSTALL(FILES
${TCLAP_BINARY_DIR}/UseTCLAP.cmake
${TCLAP_BINARY_DIR}/install/TCLAPConfig.cmake
DESTINATION lib/tclap COMPONENT Development)
# Generate the TCLAPConfig.cmake file in the build tree and configure one
# the installation tree.
# Settings specific to build trees
#
# tclap include files referenced as "tclap/foo.h"
SET(TCLAP_INCLUDE_DIRS_CONFIG ${TCLAP_SOURCE_DIR}/include)
SET(TCLAP_USE_FILE_CONFIG ${TCLAP_BINARY_DIR}/UseTCLAP.cmake)
# Configure Slicer3Config.cmake for the install tree.
CONFIGURE_FILE(${TCLAP_SOURCE_DIR}/TCLAPConfig.cmake.in
${TCLAP_BINARY_DIR}/TCLAPConfig.cmake @ONLY IMMEDIATE)
# Settings specific for installation trees
#
# tclap include files referenced as "tclap/foo.h"
SET(TCLAP_INCLUDE_DIRS_CONFIG ${CMAKE_INSTALL_PREFIX}/include)
SET(TCLAP_USE_FILE_CONFIG ${CMAKE_INSTALL_PREFIX}/lib/tclap/UseTCLAP.cmake)
# Configure Slicer3Config.cmake for the install tree.
CONFIGURE_FILE(${TCLAP_SOURCE_DIR}/TCLAPConfig.cmake.in
${TCLAP_BINARY_DIR}/install/TCLAPConfig.cmake @ONLY IMMEDIATE)
# The TCLAP source tree.
SET(TCLAP_SOURCE_DIR "@TCLAP_SOURCE_DIR@")
# The TCLAP include directories.
SET(TCLAP_INCLUDE_DIRS "@TCLAP_INCLUDE_DIRS_CONFIG@")
# The TCLAP USE file
SET(TCLAP_USE_FILE "@TCLAP_USE_FILE_CONFIG@")
INCLUDE_DIRECTORIES(BEFORE ${TCLAP_INCLUDE_DIRS})
#
# Slicer3Config.cmake - Slicer3 CMake configuration file for external projects
#
# This file is configured by Slicer3 and used by UseSlicer3.cmake module
# to load Slicer3's settings for an external project. External projects
# can use these setting to build new modules against a Slicer3 build tree
# or a Slicer3 installation.
#
# The Slicer3 include file directories.
SET(Slicer3_INCLUDE_DIRS "@Slicer3_INCLUDE_DIRS_CONFIG@")
# The Slicer3 library directories.
SET(Slicer3_LIBRARY_DIRS "@Slicer3_LIBRARY_DIRS_CONFIG@")
# The C and C++ flags added by Slicer3 to the cmake-configured flags.
SET(Slicer3_REQUIRED_C_FLAGS "@Slicer3_REQUIRED_C_FLAGS@")
SET(Slicer3_REQUIRED_CXX_FLAGS "@Slicer3_REQUIRED_CXX_FLAGS@")
SET(Slicer3_REQUIRED_LINK_FLAGS "@Slicer3_REQUIRED_LINK_FLAGS@")
# The Slicer3 version number
SET(Slicer3_VERSION_MAJOR "@Slicer3_VERSION_MAJOR@")
SET(Slicer3_VERSION_MINOR "@Slicer3_VERSION_MINOR@")
SET(Slicer3_VERSION_PATCH "@Slicer3_VERSION_PATCH@")
# The location of the UseSlicer3.cmake file.
SET(Slicer3_USE_FILE "@Slicer3_USE_FILE_CONFIG@")
# The build settings file.
SET(Slicer3_BUILD_SETTINGS_FILE "@Slicer3_BUILD_SETTINGS_FILE@")
# Whether Slicer3 was built with shared libraries.
SET(Slicer3_BUILD_SHARED "@BUILD_SHARED_LIBS@")
# Components needed to build modules from outside a Slicer3 build tree or
# from outside a Slicer3 installation tree
SET(TCLAP_DIR "@TCLAP_DIR_CONFIG@")
SET(ModuleDescriptionParser_DIR "@ModuleDescriptionParser_DIR_CONFIG@")
SET(GenerateCLP_DIR "@GenerateCLP_DIR_CONFIG@")
SET(GenerateCLP_USE_FILE "@GenerateCLP_USE_FILE_CONFIG@")
SET(GENERATECLP_EXE "@GENERATECLP_EXE_CONFIG@")
#
# This file sets up the include directories, link directories and compiler
# settings for a project to use Slicer3. Such projects could provide new
# Slicer3 modules built against a Slicer3 build tree or a Slicer3 installation.
#
FIND_PACKAGE(TCLAP REQUIRED)
IF(TCLAP_FOUND)
INCLUDE(${TCLAP_USE_FILE})
ENDIF(TCLAP_FOUND)
FIND_PACKAGE(ModuleDescriptionParser REQUIRED)
IF(ModuleDescriptionParser_FOUND)
INCLUDE(${ModuleDescriptionParser_USE_FILE})
ENDIF(ModuleDescriptionParser_FOUND)
FIND_PACKAGE(GenerateCLP REQUIRED)
IF(GenerateCLP_FOUND)
INCLUDE(${GenerateCLP_USE_FILE})
ENDIF(GenerateCLP_FOUND)
#IF(Slicer3_BUILD_SETTINGS_FILE)
# INCLUDE(${CMAKE_ROOT}/Modules/CMakeImportBuildSettings.cmake)
# CMAKE_IMPORT_BUILD_SETTINGS(${Slicer3_BUILD_SETTINGS_FILE})
#ENDIF(Slicer3_BUILD_SETTINGS_FILE)
# Add compiler flags needed to use Slicer3.
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${Slicer3_REQUIRED_C_FLAGS}")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Slicer3_REQUIRED_CXX_FLAGS}")
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${Slicer3_REQUIRED_LINK_FLAGS}")
SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${Slicer3_REQUIRED_LINK_FLAGS}")
SET(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${Slicer3_REQUIRED_LINK_FLAGS}")
# Add include directories needed to use Slicer3.
INCLUDE_DIRECTORIES(BEFORE ${Slicer3_INCLUDE_DIRS})
# Add link directories needed to use Slicer3.
LINK_DIRECTORIES(${Slicer3_LIBRARY_DIRS})
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