Skip to content

Commit

Permalink
qml_plugin.prf: Use and prefer QML_IMPORT_VERSION over IMPORT_VERSION
Browse files Browse the repository at this point in the history
qmltypes.prf does the same and the name is nicer.

Change-Id: I3364f7a244a941a4c6178cf87c65e289dc64ca22
Reviewed-by: Maximilian Goldstein <[email protected]>
Reviewed-by: Shawn Rutledge <[email protected]>
Reviewed-by: Fabian Kosmale <[email protected]>
  • Loading branch information
Ulf Hermann committed Jan 17, 2020
1 parent c70208c commit 1e65445
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions mkspecs/features/qml_plugin.prf
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,13 @@ load(qt_common)
# against concurrent wrapper creation by omitting it during build passes.
# However, creating the actual targets is reserved to the build passes.
build_pass|!debug_and_release {
isEmpty(IMPORT_VERSION) {
isEmpty(QML_IMPORT_VERSION):!isEmpty(IMPORT_VERSION): QML_IMPORT_VERSION = $$IMPORT_VERSION
isEmpty(QML_IMPORT_VERSION) {
no_cxx_module {
IMPORT_VERSION = $$section(MODULE_VERSION, ., 0, 1)
isEmpty(IMPORT_VERSION): error("Must set IMPORT_VERSION")
QML_IMPORT_VERSION = $$section(MODULE_VERSION, ., 0, 1)
isEmpty(QML_IMPORT_VERSION): error("Must set QML_IMPORT_VERSION")
} else {
IMPORT_VERSION = $$section(QT.$${CXX_MODULE}.VERSION, ., 0, 1)
QML_IMPORT_VERSION = $$section(QT.$${CXX_MODULE}.VERSION, ., 0, 1)
}
}

Expand All @@ -107,7 +108,7 @@ load(qt_common)
}

qmltypes.target = qmltypes
qmltypes.commands = $$QMLPLUGINDUMP -nonrelocatable $$QMAKE_QMLPLUGINDUMP_FLAGS $$replace(IMPORT_NAME, /, .) $$IMPORT_VERSION > $$QMLTYPEFILE
qmltypes.commands = $$QMLPLUGINDUMP -nonrelocatable $$QMAKE_QMLPLUGINDUMP_FLAGS $$replace(IMPORT_NAME, /, .) $$QML_IMPORT_VERSION > $$QMLTYPEFILE
qmltypes.depends = $$QMAKE_RESOLVED_TARGET
} else {
qmltypes.CONFIG += recursive
Expand Down

0 comments on commit 1e65445

Please sign in to comment.