From 3d0543c444bfbaea52b632a4069ce338f216fa40 Mon Sep 17 00:00:00 2001 From: "Vladimir Golovnev (Glassez)" Date: Sun, 27 Sep 2020 22:19:50 +0300 Subject: [PATCH] Fix static build with Qt < 5.14 --- src/app/CMakeLists.txt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/app/CMakeLists.txt b/src/app/CMakeLists.txt index 30b2b9b10..959a15d06 100644 --- a/src/app/CMakeLists.txt +++ b/src/app/CMakeLists.txt @@ -152,10 +152,11 @@ endif() if (GUI) target_link_libraries(qbt_app PRIVATE qbt_gui) if ((CMAKE_SYSTEM_NAME STREQUAL "Windows") OR (CMAKE_SYSTEM_NAME STREQUAL "Darwin")) - qt5_import_plugins(qbt_app - INCLUDE Qt5::QSvgIconPlugin - INCLUDE Qt5::QSvgPlugin - ) + if (Qt5_VERSION VERSION_LESS 5.14) + set_property(TARGET qbt_app APPEND PROPERTY QT_PLUGINS Qt5::QSvgIconPlugin Qt5::QSvgPlugin) + else() + qt_import_plugins(qbt_app INCLUDE Qt5::QSvgIconPlugin Qt5::QSvgPlugin) + endif() endif() endif()