Commit 28fed47f authored by Guillaume Pasero's avatar Guillaume Pasero

COMP: allow GeoTIFF and TIFF to be disabled when no 3rd party drags them

parent e372b4a4
......@@ -157,14 +157,18 @@ macro(otb_module_enable otb-module _needed_by)
endif()
if(NOT ${otb-module}_ENABLED)
set(${otb-module}_ENABLED 1)
foreach(dep IN LISTS OTB_MODULE_${otb-module}_DEPENDS)
otb_module_enable(${dep} ${otb-module})
endforeach()
foreach(dep IN LISTS OTB_MODULE_${otb-module}_OPTIONAL_DEPENDS)
otb_module_enable(${dep} ${otb-module})
endforeach()
if(${otb-module}_TESTED_BY AND (OTB_BUILD_DEFAULT_MODULES OR OTB_BUILD_ALL_MODULES_FOR_TESTS OR Module_${otb-module}))
otb_module_enable(${${otb-module}_TESTED_BY} "")
# if this module has an ACTIVATION_OPTION=OFF, don't bother enable its dependencies
if(NOT (OTB_MODULE_${otb-module}_ACTIVATION_OPTION
AND NOT ${OTB_MODULE_${otb-module}_ACTIVATION_OPTION}))
foreach(dep IN LISTS OTB_MODULE_${otb-module}_DEPENDS)
otb_module_enable(${dep} ${otb-module})
endforeach()
foreach(dep IN LISTS OTB_MODULE_${otb-module}_OPTIONAL_DEPENDS)
otb_module_enable(${dep} ${otb-module})
endforeach()
if(${otb-module}_TESTED_BY AND (OTB_BUILD_DEFAULT_MODULES OR OTB_BUILD_ALL_MODULES_FOR_TESTS OR Module_${otb-module}))
otb_module_enable(${${otb-module}_TESTED_BY} "")
endif()
endif()
endif()
endmacro()
......
......@@ -27,4 +27,6 @@ otb_module(OTBGeoTIFF
DESCRIPTION
"${DOCUMENTATION}"
EXCLUDE_FROM_DEFAULT
)
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