summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2021-02-11 18:32:20 +0100
committerUlf Hermann <ulf.hermann@qt.io>2021-02-12 11:30:43 +0100
commit953ea29328db71ac7a8ef177ecbc2329367b9170 (patch)
tree9b03d0d43c86203aa2281ed1bdad9f578b224831
parent4cc91a6a0e4f9063233a4d6554ae64855cf99c14 (diff)
Deprecate qmlplugindump
You should use qmltyperegistrar these days. [ChangeLog][QML][Important Behavior Changes] qmlplugindump is deprecated. Instead of using qmlplugindump to generate qmltypes files by loading and analyzing the pre-built plugins, you should declare your QML types using QML_ELEMENT and friends. Then you can automatically generate the qmltypes files at compile time using qmltyperegistrar. Fixes: QTBUG-91089 Change-Id: Iebd1b71a8e36c311d1590cb10128f9fc6d5e318c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
-rw-r--r--tests/auto/qml/qmlplugindump/data/dumper/Dummy/plugins.qmltypes2
-rw-r--r--tests/auto/qml/qmlplugindump/data/dumper/ExtendedType/plugins.qmltypes2
-rw-r--r--tests/auto/qml/qmlplugindump/data/dumper/Imports/plugins.qmltypes2
-rw-r--r--tests/auto/qml/qmlplugindump/data/dumper/Versions/plugins.qmltypes2
-rw-r--r--tools/qmlplugindump/main.cpp7
5 files changed, 15 insertions, 0 deletions
diff --git a/tests/auto/qml/qmlplugindump/data/dumper/Dummy/plugins.qmltypes b/tests/auto/qml/qmlplugindump/data/dumper/Dummy/plugins.qmltypes
index 76c3de33dd..211c8c6986 100644
--- a/tests/auto/qml/qmlplugindump/data/dumper/Dummy/plugins.qmltypes
+++ b/tests/auto/qml/qmlplugindump/data/dumper/Dummy/plugins.qmltypes
@@ -5,6 +5,8 @@ import QtQuick.tooling 1.2
//
// This file was auto-generated by:
// 'qmlplugindump -nonrelocatable -noforceqtquick dumper.Dummy 1.0 .'
+//
+// qmlplugindump is deprecated! You should use qmltyperegistrar instead.
Module {
Component {
diff --git a/tests/auto/qml/qmlplugindump/data/dumper/ExtendedType/plugins.qmltypes b/tests/auto/qml/qmlplugindump/data/dumper/ExtendedType/plugins.qmltypes
index ded5054e14..e09cbd6218 100644
--- a/tests/auto/qml/qmlplugindump/data/dumper/ExtendedType/plugins.qmltypes
+++ b/tests/auto/qml/qmlplugindump/data/dumper/ExtendedType/plugins.qmltypes
@@ -5,6 +5,8 @@ import QtQuick.tooling 1.2
//
// This file was auto-generated by:
// 'qmlplugindump -nonrelocatable -noforceqtquick dumper.ExtendedType 1.1 .'
+//
+// qmlplugindump is deprecated! You should use qmltyperegistrar instead.
Module {
Component {
diff --git a/tests/auto/qml/qmlplugindump/data/dumper/Imports/plugins.qmltypes b/tests/auto/qml/qmlplugindump/data/dumper/Imports/plugins.qmltypes
index 992ce6087f..95135a904d 100644
--- a/tests/auto/qml/qmlplugindump/data/dumper/Imports/plugins.qmltypes
+++ b/tests/auto/qml/qmlplugindump/data/dumper/Imports/plugins.qmltypes
@@ -5,6 +5,8 @@ import QtQuick.tooling 1.2
//
// This file was auto-generated by:
// 'qmlplugindump -nonrelocatable -noforceqtquick dumper.Imports 1.0 .'
+//
+// qmlplugindump is deprecated! You should use qmltyperegistrar instead.
Module {
Component {
diff --git a/tests/auto/qml/qmlplugindump/data/dumper/Versions/plugins.qmltypes b/tests/auto/qml/qmlplugindump/data/dumper/Versions/plugins.qmltypes
index dd2832b4ae..fef02e317c 100644
--- a/tests/auto/qml/qmlplugindump/data/dumper/Versions/plugins.qmltypes
+++ b/tests/auto/qml/qmlplugindump/data/dumper/Versions/plugins.qmltypes
@@ -5,6 +5,8 @@ import QtQuick.tooling 1.2
//
// This file was auto-generated by:
// 'qmlplugindump -nonrelocatable -noforceqtquick dumper.Versions 1.1 .'
+//
+// qmlplugindump is deprecated! You should use qmltyperegistrar instead.
Module {
Component {
diff --git a/tools/qmlplugindump/main.cpp b/tools/qmlplugindump/main.cpp
index c3a08d72ab..e5da5c59aa 100644
--- a/tools/qmlplugindump/main.cpp
+++ b/tools/qmlplugindump/main.cpp
@@ -1157,6 +1157,11 @@ int main(int argc, char *argv[])
}
}
+ std::cerr << "qmlplugindump is deprecated.\n"
+ << "Please declare your types using QML_ELEMENT and related macros.\n"
+ << "Then utilize the build system to invoke qmltyperegistrar in order to\n"
+ << "generate qmltypes files.\n";
+
if (action == Uri) {
if (positionalArgs.size() != 3 && positionalArgs.size() != 4) {
std::cerr << "Incorrect number of positional arguments" << std::endl;
@@ -1350,6 +1355,8 @@ int main(int argc, char *argv[])
"//\n"
"// This file was auto-generated by:\n"
"// '%1 %2'\n"
+ "//\n"
+ "// qmlplugindump is deprecated! You should use qmltyperegistrar instead.\n"
"\n").arg(QFileInfo(args.at(0)).baseName(), args.mid(1).join(QLatin1Char(' '))));
qml.writeStartObject("Module");