summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-01-28 01:00:39 +0100
committerLiang Qi <liang.qi@qt.io>2020-01-28 14:14:20 +0000
commit558fc903acc610769279da2737ad679aa9fd728d (patch)
treeebe36deb140e47ca32fea9b0753cde06f465a0fa /mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
parent089d54f06ff327f5212cb08fdbcb540066357dd5 (diff)
parentbe8c257da9a264994243c120231965ff0008ef09 (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Conflicts: src/corelib/io/qsettings.cpp src/corelib/kernel/qvariant.cpp src/corelib/serialization/qjsoncbor.cpp src/corelib/serialization/qjsonvalue.cpp src/corelib/tools/tools.pri src/gui/image/qimage.cpp src/gui/kernel/qguivariant.cpp src/widgets/kernel/qshortcut.cpp tests/auto/tools/moc/allmocs_baseline_in.json tests/auto/tools/moc/tst_moc.cpp src/opengl/qglframebufferobject.cpp Done-With: Edward Welbourne <edward.welbourne@qt.io> Done-With: Leander Beernaert <leander.beernaert@qt.io> Change-Id: Ie7f5fa646c607fe70c314bf7195f7578ded1d271
Diffstat (limited to 'mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in')
-rw-r--r--mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in22
1 files changed, 17 insertions, 5 deletions
diff --git a/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in b/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
index 7b70cfed09..b550a52c60 100644
--- a/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
+++ b/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
@@ -75,19 +75,30 @@ endif()
set(_user_specified_genex
\"$<IN_LIST:Qt5::$$CMAKE_PLUGIN_NAME,${_manual_plugins_genex};${_plugin_type_genex}>\"
)
+set(_user_specified_genex_versionless
+ \"$<IN_LIST:Qt::$$CMAKE_PLUGIN_NAME,${_manual_plugins_genex};${_plugin_type_genex}>\"
+)
string(CONCAT _plugin_genex
\"$<$<OR:\"
- # Add this plugin if it\'s in the list of manual plugins or plugins for the type
+ # Add this plugin if it\'s in the list of manually specified plugins or in the list of
+ # explicitly included plugin types.
\"${_user_specified_genex},\"
- # Add this plugin if the list of plugins for the type is empty, the PLUGIN_EXTENDS
- # is either empty or equal to the module name, and the user hasn\'t blacklisted it
+ \"${_user_specified_genex_versionless},\"
+ # Add this plugin if all of the following are true:
+ # 1) the list of explicitly included plugin types is empty
+ # 2) the QT_PLUGIN_EXTENDS property for the plugin is empty or equal to the current
+ # module name
+ # 3) the user hasn\'t explicitly excluded the plugin.
\"$<AND:\"
\"$<STREQUAL:${_plugin_type_genex},>,\"
\"$<OR:\"
- \"$<STREQUAL:$<TARGET_PROPERTY:Qt5::$${CMAKE_PLUGIN_NAME},QT_PLUGIN_EXTENDS>,Qt5::$${CMAKE_MODULE_NAME}>,\"
+ # FIXME: The value of CMAKE_MODULE_NAME seems to be wrong (e.g for Svg plugin
+ # it should be Qt::Svg instead of Qt::Gui).
+ \"$<STREQUAL:$<TARGET_PROPERTY:Qt5::$${CMAKE_PLUGIN_NAME},QT_PLUGIN_EXTENDS>,Qt::$${CMAKE_MODULE_NAME}>,\"
\"$<STREQUAL:$<TARGET_PROPERTY:Qt5::$${CMAKE_PLUGIN_NAME},QT_PLUGIN_EXTENDS>,>\"
\">,\"
- \"$<NOT:$<IN_LIST:Qt5::$${CMAKE_PLUGIN_NAME},${_no_plugins_genex}>>\"
+ \"$<NOT:$<IN_LIST:Qt5::$${CMAKE_PLUGIN_NAME},${_no_plugins_genex}>>,\"
+ \"$<NOT:$<IN_LIST:Qt::$${CMAKE_PLUGIN_NAME},${_no_plugins_genex}>>\"
\">\"
\">:Qt5::$$CMAKE_PLUGIN_NAME>\"
)
@@ -100,3 +111,4 @@ set_property(TARGET Qt5::$${CMAKE_PLUGIN_NAME} APPEND PROPERTY INTERFACE_LINK_LI
!!ENDIF
set_property(TARGET Qt5::$${CMAKE_PLUGIN_NAME} PROPERTY QT_PLUGIN_TYPE \"$$CMAKE_PLUGIN_TYPE\")
set_property(TARGET Qt5::$${CMAKE_PLUGIN_NAME} PROPERTY QT_PLUGIN_EXTENDS \"$$CMAKE_PLUGIN_EXTENDS\")
+set_property(TARGET Qt5::$${CMAKE_PLUGIN_NAME} PROPERTY QT_PLUGIN_CLASS_NAME \"$$CMAKE_PLUGIN_NAME\")