Skip to content
Snippets Groups Projects
Commit 0e0ccbac authored by Emmanuel Christophe's avatar Emmanuel Christophe
Browse files

COMP: cleaning compilation process

parent 7d456e53
No related branches found
No related tags found
No related merge requests found
......@@ -954,14 +954,28 @@ ENDIF(OTB_USE_VISU_GUI)
OPTION(BUILD_EXAMPLES "Build the Examples directory." OFF)
#-----------------------------------------------------------------------------
# The entire OTB tree should use the same include path
# Create the list of include directories needed for OTB header files.
INCLUDE(${OTB_SOURCE_DIR}/otbIncludeDirectories.cmake)
# This should be the only INCLUDE_DIRECTORIES command in the entire
# tree, except for the Utilities and Wrapping directories. We need to
# do this in one place to make sure the order is correct.
INCLUDE_DIRECTORIES(
${OTB_INCLUDE_DIRS_BUILD_TREE}
${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
${OTB_INCLUDE_DIRS_SYSTEM}
)
#-----------------------------------------------------------------------------
# Dispatch the build into the proper subdirectories.
#Note: SUBDIRS is deprecated and should be replaced by ADD_SUBDIRECTORY
SUBDIRS(Utilities Code)
#ADD_SUBDIRECTORY(Utilities)
#ADD_SUBDIRECTORY(Code)
#ADD_SUBDIRECTORY(Utilities/otbsvm)
#Note: SUBDIRS is deprecated and is replaced by ADD_SUBDIRECTORY
#SUBDIRS(Utilities Code)
ADD_SUBDIRECTORY(Utilities)
ADD_SUBDIRECTORY(Code)
IF (BUILD_EXAMPLES)
ADD_SUBDIRECTORY(Examples)
......@@ -1031,16 +1045,16 @@ CONFIGURE_FILE(${OTB_SOURCE_DIR}/otbConfigure.h.in
# The entire OTB tree should use the same include path
# Create the list of include directories needed for OTB header files.
INCLUDE(${OTB_SOURCE_DIR}/otbIncludeDirectories.cmake)
#INCLUDE(${OTB_SOURCE_DIR}/otbIncludeDirectories.cmake)
# This should be the only INCLUDE_DIRECTORIES command in the entire
# tree, except for the Utilities and Wrapping directories. We need to
# do this in one place to make sure the order is correct.
INCLUDE_DIRECTORIES(
${OTB_INCLUDE_DIRS_BUILD_TREE}
${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
${OTB_INCLUDE_DIRS_SYSTEM}
)
#INCLUDE_DIRECTORIES(
# ${OTB_INCLUDE_DIRS_BUILD_TREE}
# ${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
# ${OTB_INCLUDE_DIRS_SYSTEM}
#)
#-----------------------------------------------------------------------------
# Uninstall cmake use to uninstall OTB.
......
SUBDIRS(
Containers
Image
Mesh
Path
)
ADD_SUBDIRECTORY(Containers)
ADD_SUBDIRECTORY(Image)
ADD_SUBDIRECTORY(Mesh)
ADD_SUBDIRECTORY(Path)
......@@ -19,7 +19,10 @@ ELSE(OTB_USE_EXTERNAL_BOOST)
)
ENDIF(OTB_USE_EXTERNAL_BOOST)
#-----------------------------------------------------------------------------
# Include directories from the GDAL build tree.
SET(OTB_INCLUDE_DIRS_BUILD_TREE ${OTB_INCLUDE_DIRS_BUILD_TREE}
${GDAL_INCLUDE_DIR} )
# These directories are always needed.
SET(OTB_INCLUDE_DIRS_BUILD_TREE ${OTB_INCLUDE_DIRS_BUILD_TREE}
......@@ -97,10 +100,7 @@ SET(OTB_INCLUDE_DIRS_BUILD_TREE ${OTB_INCLUDE_DIRS_BUILD_TREE}
)
#-----------------------------------------------------------------------------
# Include directories from the GDAL build tree.
SET(OTB_INCLUDE_DIRS_BUILD_TREE ${OTB_INCLUDE_DIRS_BUILD_TREE}
${GDAL_INCLUDE_DIR} )
#-----------------------------------------------------------------------------
# Include directories from the CURL build tree.
IF(OTB_USE_CURL)
......@@ -221,10 +221,6 @@ SET(OTB_INCLUDE_DIRS_BUILD_TREE_CXX ${OTB_INCLUDE_DIRS_BUILD_TREE_CXX} )
SET(OTB_INCLUDE_DIRS_BUILD_TREE_CXX ${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
${OTB_GLU_INCLUDE_PATH} )
#For GDAL header file
SET(OTB_INCLUDE_DIRS_BUILD_TREE_CXX ${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
${GDAL_INCLUDE_DIR} )
#For EXPAT header file
IF(OTB_USE_EXTERNAL_EXPAT)
SET(OTB_INCLUDE_DIRS_BUILD_TREE_CXX ${OTB_INCLUDE_DIRS_BUILD_TREE_CXX}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment