From cc91089c4e0185d2262b35e48574c82a259f4ddb Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Tue, 14 Jul 2026 13:12:39 +0200 Subject: [PATCH] CMake: Fix git-qt-foreach output being lost in non-tty invocations There's a tty check in qt_internal_foreach_repo_run. The code reads tty_exit_CODE rather than the correct tty_exit_code. In a non-tty context (when stdout is a pipe), /usr/bin/tty prints "not a tty" and has a non-zero exit code, leading to stdout being redirected to a file named "not a tty" in every submodule. Use the right name. Pick-to: 6.8 Change-Id: I6bba544aa0e3bbe2f09925cae56f303e70643681 Reviewed-by: Joerg Bornemann (cherry picked from commit 8e218fec4753ae7ddcc79f0e6600bea87179e35f) Reviewed-by: Qt Cherry-pick Bot (cherry picked from commit 58e5ed9147debe25dc2a4fe84950bfaabe16023c) --- cmake/QtTopLevelHelpers.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/QtTopLevelHelpers.cmake b/cmake/QtTopLevelHelpers.cmake index e5ec02a0..88ea231f 100644 --- a/cmake/QtTopLevelHelpers.cmake +++ b/cmake/QtTopLevelHelpers.cmake @@ -1386,7 +1386,7 @@ function(qt_internal_foreach_repo_run) set(color_supported FALSE) set(output_goes_where "") - if(NOT tty_exit_CODE AND tty_name) + if(NOT tty_exit_code AND tty_name) set(color_supported TRUE) set(output_goes_where "OUTPUT_FILE" "${tty_name}") endif()