Automatically pick up dependencies.json file for qmlplugindump

The dependencies.json file allows to tweak the list of imports the
module is depending on, so that types implicitly imported are not
listed twice.

Task-number: QTBUG-70264
Change-Id: I7a3800e5ea713a8aaae0cddbf4e1607f92c41497
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
bb10
Kai Koehne 2018-08-30 11:40:35 +02:00
parent 4522468716
commit 27f54076cd
1 changed files with 8 additions and 0 deletions

View File

@ -110,6 +110,14 @@ load(qt_common)
load(resolve_target)
TARGETPATHBASE = $$replace(TARGETPATH, \\.\\d+\$, )
!qml1_target {
isEmpty(QMAKE_PLUGINDUMP_DEPENDENCIES_FILE):exists($$_PRO_FILE_PWD_/dependencies.json): \
QMAKE_PLUGINDUMP_DEPENDENCIES_FILE = $$_PRO_FILE_PWD_/dependencies.json
!isEmpty(QMAKE_PLUGINDUMP_DEPENDENCIES_FILE): \
QMAKE_QMLPLUGINDUMP_FLAGS += -dependencies $$shell_quote($$QMAKE_PLUGINDUMP_DEPENDENCIES_FILE)
}
qmltypes.target = qmltypes
qmltypes.commands = $$QMLPLUGINDUMP -nonrelocatable $$QMAKE_QMLPLUGINDUMP_FLAGS $$replace(TARGETPATHBASE, /, .) $$IMPORT_VERSION > $$QMLTYPEFILE
qmltypes.depends = $$QMAKE_RESOLVED_TARGET