Skip to content
This repository was archived by the owner on Mar 4, 2023. It is now read-only.

Commit 3f12f7d

Browse files
committed
fix qmlplugindump usage
1 parent 8bec430 commit 3f12f7d

File tree

2 files changed

+17
-10
lines changed

2 files changed

+17
-10
lines changed

.qmake.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ DEFINES += QT_DEPRECATED_WARNINGS QT_ASCII_CAST_WARNINGS
1010

1111
MODULE_VERSION_MAJOR = 4
1212
MODULE_VERSION_MINOR = 1
13-
MODULE_VERSION_PATCH = 0
13+
MODULE_VERSION_PATCH = 1
1414
MODULE_VERSION_IMPORT = $${MODULE_VERSION_MAJOR}.$${MODULE_VERSION_MINOR}
1515
MODULE_VERSION = $${MODULE_VERSION_MAJOR}.$${MODULE_VERSION_MINOR}.$${MODULE_VERSION_PATCH}
1616

src/imports/datasync/datasync.pro

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,21 +25,28 @@ SOURCES += \
2525

2626
OTHER_FILES += qmldir
2727

28-
generate_qmltypes {
29-
typeextra1.target = qmltypes
30-
typeextra1.depends += export LD_LIBRARY_PATH := "$$shadowed($$dirname(_QMAKE_CONF_))/lib/:$$[QT_INSTALL_LIBS]:$(LD_LIBRARY_PATH)"
31-
typeextra2.target = qmltypes
32-
typeextra2.depends += export QML2_IMPORT_PATH := "$$shadowed($$dirname(_QMAKE_CONF_))/qml/"
33-
QMAKE_EXTRA_TARGETS += typeextra1 typeextra2
34-
}
35-
3628
CONFIG += qmlcache
3729
load(qml_plugin)
3830

3931
generate_qmltypes {
40-
qmltypes.depends = ../../../qml/$$TARGETPATH/$(TARGET) #overwrite the target deps
32+
# run again to overwrite module env
33+
ldpath.name = LD_LIBRARY_PATH
34+
ldpath.value = "$$shadowed($$dirname(_QMAKE_CONF_))/lib/:$$[QT_INSTALL_LIBS]:$$(LD_LIBRARY_PATH)"
35+
qmlpath.name = QML2_IMPORT_PATH
36+
qmlpath.value = "$$shadowed($$dirname(_QMAKE_CONF_))/qml/:$$[QT_INSTALL_QML]:$$(QML2_IMPORT_PATH)"
37+
PLGDUMP_ENV = ldpath qmlpath
38+
QT_TOOL_ENV = ldpath qmlpath
39+
qtPrepareTool(QMLPLUGINDUMP, qmlplugindump)
40+
QT_TOOL_ENV =
41+
42+
#overwrite the target deps as make target is otherwise not detected
43+
qmltypes.depends = ../../../qml/$$TARGETPATH/$(TARGET)
44+
OLDDMP = $$take_first(qmltypes.commands)
45+
qmltypes.commands = $$QMLPLUGINDUMP $${qmltypes.commands}
46+
message("replaced $$OLDDMP with $$QMLPLUGINDUMP")
4147

4248
mfirst.target = all
4349
mfirst.depends += qmltypes
4450
QMAKE_EXTRA_TARGETS += mfirst
4551
}
52+

0 commit comments

Comments
 (0)