CMakeLists.txt 1.69 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11
cmake_minimum_required(VERSION 2.8.3)


project(OTB-SuperBuild)

# Path to additional CMake modules
set(CMAKE_MODULE_PATH
    ${CMAKE_SOURCE_DIR}/CMake
    ${CMAKE_MODULE_PATH})

include(ExternalProject)
12
include(CTest)
13

14 15 16 17 18
# General options
option(ENABLE_QT4 " Use QT4 in the SuperBuild" ON)
option(ENABLE_OTB_LARGE_INPUTS " Use the OTB-LargeInputs for testing" OFF)


19 20 21 22
if(WIN32)
  if(MSVC)
    set(SB_CMAKE_COMMAND ${CMAKE_COMMAND})
  endif()      
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
23
else(UNIX)
24
  set(SB_CMAKE_COMMAND env LD_LIBRARY_PATH=${CMAKE_INSTALL_PREFIX}/lib  ${CMAKE_COMMAND})
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
25
endif()
26
# Call external projects
27

Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
28
#TODO: enforce check from ITK on directory length
29

30
include(External_zlib)
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
31 32 33
include(External_jpeg)
include(External_expat)
include(External_libpng)
34 35 36
include(External_libtiff)
include(External_proj4)
include(External_geotiff)
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
37
include(External_SQLite)
38 39
include(External_geos)
include(External_OpenJpeg)
40 41 42
include(External_boost)
include(External_libKML)
include(External_curl)
43
include(External_GDAL)
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
44
include(External_fftw)
45
include(External_ITK)
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
46
include(External_OpenThreads)
47
include(External_ossim)
Rashad Kanavath's avatar
MRG  
Rashad Kanavath committed
48 49 50
include(External_muParser)
include(External_muParserX)
include(External_TinyXML)
Guillaume Pasero's avatar
Guillaume Pasero committed
51
include(External_OpenCV)
52 53 54 55

if(ENABLE_QT4)
  include(External_qt4)
endif()
56 57 58 59

# TODO

# Call OTB
60 61 62 63

# 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)

64 65 66 67
if(ENABLE_OTB_LARGE_INPUTS)
  find_path(OTB_DATA_LARGEINPUT_ROOT OTBData.readme $ENV{OTB_DATA_LARGEINPUT_ROOT})
endif()

68
include(External_OTB)
69

70 71 72
option(BUILD_ICE_APPLICATION "Build the Ice application (requires glfw and glut)" OFF)

include(External_Ice)
73

74 75 76
if(ENABLE_QT4)
  include(External_Monteverdi2)
endif()
77

78
#include(External_Monteverdi)