diff --git a/src/corelib/Qt6CoreMacros.cmake b/src/corelib/Qt6CoreMacros.cmake index bfecc943cb7..08c5cc57a7b 100644 --- a/src/corelib/Qt6CoreMacros.cmake +++ b/src/corelib/Qt6CoreMacros.cmake @@ -1169,7 +1169,7 @@ function(qt6_extract_metatypes target) VERBATIM ) - if(NOT CMAKE_GENERATOR MATCHES "^Ninja") + if(CMAKE_GENERATOR MATCHES " Makefiles") # Work around https://gitlab.kitware.com/cmake/cmake/-/issues/19005 to trigger the command # that generates ${metatypes_file}. add_custom_command(