Commit 1cdebe4b authored by Rashad Kanavath's avatar Rashad Kanavath
Browse files

PKG: check MVD and OTB dependencies only if OTB_OF_SOURCE_BUILD is false

parent 6e306cb5
......@@ -57,18 +57,27 @@ macro(macro_create_targets_for_package pkg)
COMMAND ${CMAKE_COMMAND} --build "." --target install
WORKING_DIRECTORY "${Monteverdi_BINARY_DIR}"
)
else() #Unxies Using SuperBuild
if(ENABLE_MONTEVERDI)
else() #Using SuperBuild
#For out of source build,
#we assume the otb is built correctly with superbuild
if(OUT_OF_SOURCE_BUILD)
add_custom_target(PACKAGE-${pkg}-check
COMMAND ${CMAKE_COMMAND} -E echo "Building PACKAGE-${pkg}-check"
DEPENDS MVD
)
COMMAND ${CMAKE_COMMAND} -E echo "Building PACKAGE-${pkg}-check")
else(OUT_OF_SOURCE_BUILD)
if(ENABLE_MONTEVERDI)
add_custom_target(PACKAGE-${pkg}-check
COMMAND ${CMAKE_COMMAND} -E echo "Building PACKAGE-${pkg}-check"
DEPENDS MVD
WORKING_DIRECTORY ${SUPERBUILD_BINARY_DIR}
)
else(ENABLE_MONTEVERDI)
add_custom_target(PACKAGE-${pkg}-check
COMMAND ${CMAKE_COMMAND} -E echo "Building PACKAGE-${pkg}-check"
DEPENDS OTB
)
endif(ENABLE_MONTEVERDI)
add_custom_target(PACKAGE-${pkg}-check
COMMAND ${CMAKE_COMMAND} -E echo "Building PACKAGE-${pkg}-check"
DEPENDS OTB
WORKING_DIRECTORY ${SUPERBUILD_BINARY_DIR}
)
endif(ENABLE_MONTEVERDI)
endif(OUT_OF_SOURCE_BUILD)
endif()
add_dependencies(PACKAGE-${pkg}-check PACKAGE-TOOLS)
......
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