Skip to content

Commit

Permalink
build: Fix dependency management for workbenches
Browse files Browse the repository at this point in the history
Previously the workbench was not disabled even when dependencies
were unmet, resulting in eventual compile failure.
  • Loading branch information
plaes committed Oct 8, 2020
1 parent fd9cdb9 commit b489f2b
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions cMake/FreeCAD_Helpers/CheckInterModuleDependencies.cmake
Expand Up @@ -6,11 +6,12 @@ macro(CheckInterModuleDependencies)
# modules. Warns if any of the prerequisite modules are disabled.
function(REQUIRES_MODS dependent)
if(${dependent})
foreach(prerequisite ${ARGN})
foreach(prerequisite IN LISTS ARGN)
if(NOT ${prerequisite})
message(WARNING
"${dependent} requires ${ARGN} each be ON, but "
"${prerequisite} is \"${${prerequisite}}\"")
message(STATUS "${dependent} requires ${prerequisite} to be ON, but it"
" is \"${${prerequisite}}\"")
set(${dependent} OFF PARENT_SCOPE)
break()
endif(NOT ${prerequisite})
endforeach()
endif(${dependent})
Expand Down

0 comments on commit b489f2b

Please sign in to comment.