From 08e431956a9551312d954d7d91063ee3125bff4b Mon Sep 17 00:00:00 2001 From: Tasuku Suzuki Date: Tue, 17 Oct 2023 09:18:58 +0900 Subject: [PATCH] CMake: Fix Qt toolchain file recursive inclusion '.' in the regexp must be escaped. e.g. "/qt/toolchain.cmake" matches "/qt.toolchain.cmake$" Pick-to: 6.5 Change-Id: Ib6b66349e1619908a33b4a11d79f7ba19d0e8fdc Reviewed-by: Joerg Bornemann (cherry picked from commit 6544a23603b46c1e2e7c4bd7728ec4dbdb6aec16) Reviewed-by: Qt Cherry-pick Bot --- cmake/QtAutoDetect.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/QtAutoDetect.cmake b/cmake/QtAutoDetect.cmake index 0e2ede24eff..5652124d915 100644 --- a/cmake/QtAutoDetect.cmake +++ b/cmake/QtAutoDetect.cmake @@ -276,7 +276,7 @@ function(qt_auto_detect_cmake_config) endfunction() function(qt_auto_detect_cyclic_toolchain) - if(CMAKE_TOOLCHAIN_FILE AND CMAKE_TOOLCHAIN_FILE MATCHES "/qt.toolchain.cmake$") + if(CMAKE_TOOLCHAIN_FILE AND CMAKE_TOOLCHAIN_FILE MATCHES "/qt\\.toolchain\\.cmake$") message(FATAL_ERROR "Woah there! You can't use the Qt generated qt.toolchain.cmake file to configure " "qtbase, because that will create a toolchain file that includes itself!\n"