-
Notifications
You must be signed in to change notification settings - Fork 75
/
Copy pathdeployment.pri
107 lines (89 loc) · 5.14 KB
/
deployment.pri
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
include(../paths.pri)
TARGETPATH = $$replace(uri, \\., /)
DESIGNER = designer
DESTDIR = $$OUT_PWD/../../imports/$$TARGETPATH
isEmpty(PLUGIN_VERSION): PLUGIN_VERSION = 1.0
# ========== copy additional files ==========
copyqmlinfra.input = QML_INFRA_FILES
copyqmlinfra.output = $$OUT_PWD/../../imports/$$TARGETPATH/${QMAKE_FILE_IN_BASE}${QMAKE_FILE_EXT}
!win32: copyqmlinfra.commands = $$QMAKE_MKDIR $$shell_path($$dirname(copyqmlinfra.output)) $$escape_expand(\n\t)
copyqmlinfra.commands += $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
copyqmlinfra.CONFIG += no_link no_clean
copyqmlinfra.variable_out = PRE_TARGETDEPS
QMAKE_EXTRA_COMPILERS += copyqmlinfra
copyqmlprivateinfra.input = QML_PRIVATE_INFRA_FILES
copyqmlprivateinfra.output = $$OUT_PWD/../../imports/$$TARGETPATH/Private/${QMAKE_FILE_IN_BASE}${QMAKE_FILE_EXT}
!win32: copyqmlprivateinfra.commands = $$QMAKE_MKDIR $$shell_path($$dirname(copyqmlprivateinfra.output)) $$escape_expand(\n\t)
copyqmlprivateinfra.commands += $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
copyqmlprivateinfra.CONFIG += no_link no_clean
copyqmlprivateinfra.variable_out = PRE_TARGETDEPS
QMAKE_EXTRA_COMPILERS += copyqmlprivateinfra
copyqmldesigner.input = QML_DESIGNER_FILES
copyqmldesigner.output = $$OUT_PWD/../../imports/$$DESIGNER/$$TARGETPATH/designer/
copyqmldesigner.commands = $(COPY_DIR) ${QMAKE_FILE_IN} $$shell_path($$OUT_PWD/../../imports/$$DESIGNER/$$TARGETPATH/designer/)
copyqmldesigner.CONFIG += no_link no_clean
copyqmldesigner.variable_out = PRE_TARGETDEPS
QMAKE_EXTRA_COMPILERS += copyqmldesigner
exists(QTCREATOR_INSTALL_DIR): CONFIG(release, debug|release): {
copyqmlpropertyeditor.input = QML_PROPERTY_EDITOR_FILES
copyqmlpropertyeditor.output = $$OUT_PWD/../../imports/$$DESIGNER/$$TARGETPATH/propertyEditorQmlSources/${QMAKE_FILE_IN_BASE}${QMAKE_FILE_EXT}
!win32: copyqmlpropertyeditor.commands = $$QMAKE_MKDIR $$shell_path($$dirname(copyqmlpropertyeditor.output)) $$escape_expand(\n\t)
copyqmlpropertyeditor.commands += $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
copyqmlpropertyeditor.CONFIG += no_link no_clean
copyqmlpropertyeditor.variable_out = PRE_TARGETDEPS
QMAKE_EXTRA_COMPILERS += copyqmlpropertyeditor
}
android: {
copyjavafiles.input = JAVAFILES
copyjavafiles.output = $$OUT_PWD/../../src/android/java/
copyjavafiles.commands = $$QMAKE_MKDIR $$shell_path($$dirname(copyjavafiles.output)) $$escape_expand(\n\t)
copyjavafiles.commands += $(COPY_DIR) ${QMAKE_FILE_IN} $$shell_path($$OUT_PWD/../../src/android/java/)
copyjavafiles.CONFIG += no_link no_clean
copyjavafiles.variable_out = PRE_TARGETDEPS
QMAKE_EXTRA_COMPILERS += copyjavafiles
}
win32: QMAKE_DEL_FILE = del /q /f
!win32:QMAKE_DEL_FILE = rm -r -f
QMAKE_CLEAN += $$OUT_PWD/../../imports/$$TARGETPATH/
# ========== install additional files ==========
isEmpty(QMLPLUGINDUMP): QMLPLUGINDUMP = 1
equals(QMLPLUGINDUMP, 1): !ios: !android: CONFIG(release, debug|release): {
dumppluginqmltypes.CONFIG = no_files no_path
dumppluginqmltypes.commands = $$dirname(QMAKE_QMAKE)/qmlplugindump -nonrelocatable "$$uri $$PLUGIN_VERSION $$shell_path($$OUT_PWD/../../imports/) > $$shell_path($$OUT_PWD/../../imports/$$TARGETPATH/plugins.qmltypes)"
INSTALLS += dumppluginqmltypes
copypluginqmltypes.CONFIG = no_files no_path
# make sure the directory exists
!win32: copypluginqmltypes.commands = $$QMAKE_MKDIR $$shell_path(${DESTDIR}$$[QT_INSTALL_QML]/$$TARGETPATH/) $$escape_expand(\n\t)
!win32: copypluginqmltypes.commands += $$QMAKE_COPY $$shell_path($$OUT_PWD/../../imports/$$TARGETPATH/plugins.qmltypes) $$shell_path(${DESTDIR}$$[QT_INSTALL_QML]/$$TARGETPATH/plugins.qmltypes)
# ignore any errors on Windows
win32: copypluginqmltypes.commands = xcopy $$shell_path($$OUT_PWD/../../imports/$$TARGETPATH/plugins.qmltypes) $$shell_path($$[QT_INSTALL_QML]/$$TARGETPATH/plugins.qmltypes) /C /E /Q /Y $$escape_expand(\n\t)
win32: copypluginqmltypes.commands = exit 0
INSTALLS += copypluginqmltypes
}
copyqmlinfra_install.files = $$QML_INFRA_FILES
copyqmlinfra_install.path = $$[QT_INSTALL_QML]/$$TARGETPATH
INSTALLS += copyqmlinfra_install
copyqmlprivateinfra_install.files = $$QML_PRIVATE_INFRA_FILES
copyqmlprivateinfra_install.path = $$[QT_INSTALL_QML]/$$TARGETPATH/Private
INSTALLS += copyqmlprivateinfra_install
copyqmldesigner_install.files = $$QML_DESIGNER_FILES
copyqmldesigner_install.path = $$[QT_INSTALL_QML]/$$TARGETPATH
INSTALLS += copyqmldesigner_install
exists(QTCREATOR_INSTALL_DIR): CONFIG(release, debug|release): {
copyqmlpropertyeditor_install.files = $$QML_PROPERTY_EDITOR_FILES
copyqmlpropertyeditor_install.path = $$QTCREATOR_INSTALL_DIR/share/qtcreator/qmldesigner/propertyEditorQmlSources/$$TARGETPATH
INSTALLS += copyqmlpropertyeditor_install
}
android: {
copyjavafiles_install.CONFIG = no_files no_path
copyjavafiles_install.commands += $(COPY_DIR) $$shell_path($$OUT_PWD/../../src/android) $$shell_path($$[QT_INSTALL_ARCHDATA]/src)
INSTALLS += copyjavafiles_install
}
target.path = $$[QT_INSTALL_QML]/$$TARGETPATH
INSTALLS += target
OTHER_FILES += \
$$QML_INFRA_FILES \
$$QML_PRIVATE_INFRA_FILES \
$$QML_DESIGNER_FILES \
$$QML_PROPERTY_EDITOR_FILES \
$$JAVAFILES