From 67d845a027b6005ba3ae1708b4c0ea5b62fbccc8 Mon Sep 17 00:00:00 2001 From: Alexey Edelev Date: Wed, 23 Aug 2023 16:40:39 +0200 Subject: [PATCH] Point out that STATIC QML plugins require direct linking In qt_add_qml_module documentation we never mention targets using the STATIC QML plugins need to link to corresponding QML plugins. Add couple words in addition to the Q_IMPORT_QML_PLUGIN note. Task-number: QTBUG-114688 Change-Id: I2e484250ea9d06dc8824aea23a7c4c106f01884f Reviewed-by: Amir Masoud Abdol Reviewed-by: Alexandru Croitor (cherry picked from commit 42b0cb7cca252a9b3ad64f951fd366e1d0b29ad0) Reviewed-by: Qt Cherry-pick Bot --- src/qml/doc/src/cmake/qt_add_qml_module.qdoc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/qml/doc/src/cmake/qt_add_qml_module.qdoc b/src/qml/doc/src/cmake/qt_add_qml_module.qdoc index 717bd5e0aa..2c63eb12e3 100644 --- a/src/qml/doc/src/cmake/qt_add_qml_module.qdoc +++ b/src/qml/doc/src/cmake/qt_add_qml_module.qdoc @@ -112,9 +112,13 @@ For cases where the QML module needs a custom plugin class implementation, the \l{NO_GENERATE_PLUGIN_SOURCE} and usually the \l{NO_PLUGIN_OPTIONAL} options will be needed. +The \c STATIC QML modules also generate the static QML plugins if +\c NO_PLUGIN is not specified. Targets that import such \c STATIC QML modules +also need to explicitly link to corresponding QML plugins. + \note When using static linking, it might be necessary to use -\c Q_IMPORT_QML_PLUGIN to ensure that the QML plugin is correctly linked. +\l {Q_IMPORT_QML_PLUGIN} to ensure that the QML plugin is correctly linked. \section3 Plugin target with no backing target