diff --git a/cmake/FindQt5.cmake b/cmake/FindQt5.cmake index dbbb07681f3..4fde452733d 100644 --- a/cmake/FindQt5.cmake +++ b/cmake/FindQt5.cmake @@ -78,7 +78,7 @@ endif() set(Qt5_FOUND ${Qt6_FOUND}) set(Qt5_VERSION ${Qt6_VERSION}) -foreach(tool qmake lrelease moc rcc qhelpgenerator) +foreach(tool qmake lrelease lupdate moc rcc qhelpgenerator) if (TARGET Qt6::${tool} AND NOT TARGET Qt5::${tool}) add_executable(Qt5::${tool} IMPORTED GLOBAL) get_target_property(imported_location Qt6::${tool} IMPORTED_LOCATION) diff --git a/cmake/QtCreatorTranslations.cmake b/cmake/QtCreatorTranslations.cmake index a674f37be6d..a9da1e52476 100644 --- a/cmake/QtCreatorTranslations.cmake +++ b/cmake/QtCreatorTranslations.cmake @@ -95,7 +95,7 @@ function(_create_ts_custom_target name) endfunction() function(add_translation_targets file_prefix) - if (NOT TARGET Qt5::lrelease) + if (NOT TARGET Qt5::lrelease OR NOT TARGET Qt5::lupdate) # No Qt translation tools were found: Skip this directory message(WARNING "No Qt translation tools found, skipping translation targets. Add find_package(Qt5 COMPONENTS LinguistTools) to CMake to enable.") return()