Commit 57573de8 authored by Guillaume Pasero's avatar Guillaume Pasero

ENH: global options for Qt4 and LargeInputs

parent e9dfa3a0
......@@ -8,11 +8,22 @@ set(${proj}_DEPENDENCIES)
set(BUILD_EXAMPLES ON)
if(USE_SYSTEM_QT4)
set(OTB_SB_WRAP_QT_CONFIG)
set(OTB_SB_WRAP_QT_CONFIG -DOTB_WRAP_QT:BOOL=ON)
if(ENABLE_OTB_LARGE_INPUTS)
set(OTB_SB_LARGEINPUT_CONFIG
-DOTB_DATA_USE_LARGEINPUT:BOOL=ON
-DOTB_DATA_LARGEINPUT_ROOT:PATH=${OTB_DATA_LARGEINPUT_ROOT}
)
else()
if(MSVC)
set(OTB_SB_LARGEINPUT_CONFIG
-DOTB_DATA_USE_LARGEINPUT:BOOL=OFF
)
endif()
if(ENABLE_QT4)
if(USE_SYSTEM_QT4)
set(OTB_SB_WRAP_QT_CONFIG -DOTB_WRAP_QT:BOOL=ON)
else()
if(MSVC)
set(OTB_SB_WRAP_QT_CONFIG -DOTB_WRAP_QT:BOOL=ON)
list(APPEND ${proj}_DEPENDENCIES QT4)
else(UNIX)
......@@ -20,6 +31,9 @@ else()
message(STATUS " Qt4 is not built by SuperBuild. You need to install it via package manager.")
set(OTB_SB_WRAP_QT_CONFIG -DOTB_WRAP_QT:BOOL=OFF)
endif()
endif()
else()
set(OTB_SB_WRAP_QT_CONFIG -DOTB_WRAP_QT:BOOL=OFF)
endif()
if(USE_SYSTEM_GDAL)
......@@ -192,6 +206,7 @@ ExternalProject_Add(${proj}
${OTB_SB_LIBKML_CONFIG}
${OTB_SB_OPENCV_CONFIG}
${OTB_SB_CURL_CONFIG}
${OTB_SB_LARGEINPUT_CONFIG}
CMAKE_COMMAND ${SB_CMAKE_COMMAND}
)
......
......@@ -11,6 +11,11 @@ set(CMAKE_MODULE_PATH
include(ExternalProject)
include(CTest)
# General options
option(ENABLE_QT4 " Use QT4 in the SuperBuild" ON)
option(ENABLE_OTB_LARGE_INPUTS " Use the OTB-LargeInputs for testing" OFF)
if(WIN32)
if(MSVC)
set(SB_CMAKE_COMMAND ${CMAKE_COMMAND})
......@@ -44,7 +49,10 @@ include(External_muParser)
include(External_muParserX)
include(External_TinyXML)
include(External_OpenCV)
include(External_qt4)
if(ENABLE_QT4)
include(External_qt4)
endif()
# TODO
......@@ -53,11 +61,17 @@ include(External_qt4)
# set OTB_DATA_ROOT to run test
find_path(OTB_DATA_ROOT README-OTB-Data PATHS $ENV{OTB_DATA_ROOT} ${OTB-SuperBuild_SOURCE_DIR}/../OTB-Data)
if(ENABLE_OTB_LARGE_INPUTS)
find_path(OTB_DATA_LARGEINPUT_ROOT OTBData.readme $ENV{OTB_DATA_LARGEINPUT_ROOT})
endif()
include(External_OTB)
option(BUILD_ICE_APPLICATION "Build the Ice application (requires glfw and glut)" OFF)
include(External_Ice)
include(External_Monteverdi2)
if(ENABLE_QT4)
include(External_Monteverdi2)
endif()
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