cmake: actually print the cycle in the error message

pull/13555/head
Dylan Baker 3 months ago committed by Eli Schwartz
parent 188869724a
commit 7813354460
  1. 4
      mesonbuild/cmake/interpreter.py

@ -1060,7 +1060,9 @@ class CMakeInterpreter:
def detect_cycle(tgt: T.Union[ConverterTarget, ConverterCustomTarget]) -> None:
if tgt.name in processing:
raise CMakeException('Cycle in CMake inputs/dependencies detected')
processing.append(tgt.name)
stack = ' -> '.join(processing)
raise CMakeException(f'Cycle in CMake inputs/dependencies detected: {stack}')
processing.append(tgt.name)
def resolve_ctgt_ref(ref: CustomTargetReference) -> T.Union[IdNode, IndexNode]:

Loading…
Cancel
Save