1 # This file was generated by an application wizard of Qt Creator.
2 # The code below handles deployment to Symbian and Maemo, aswell as copying
3 # of the application data to shadow build directories on desktop.
4 # It is recommended not to modify this file, since newer versions of Qt Creator
5 # may offer an updated version of it.
7 defineTest(qtcAddDeployment) {
8 for(deploymentfolder, DEPLOYMENTFOLDERS) {
9 item = item$${deploymentfolder}
10 itemsources = $${item}.sources
11 $$itemsources = $$eval($${deploymentfolder}.source)
12 itempath = $${item}.path
13 $$itempath= $$eval($${deploymentfolder}.target)
19 MAINPROFILEPWD = $$PWD
22 isEmpty(ICON):exists($${TARGET}.svg):ICON = $${TARGET}.svg
23 isEmpty(TARGET.EPOCHEAPSIZE):TARGET.EPOCHEAPSIZE = 0x20000 0x2000000
26 for(deploymentfolder, DEPLOYMENTFOLDERS) {
27 source = $$MAINPROFILEPWD/$$eval($${deploymentfolder}.source)
28 source = $$replace(source, /, \\)
29 sourcePathSegments = $$split(source, \\)
30 target = $$OUT_PWD/$$eval($${deploymentfolder}.target)/$$last(sourcePathSegments)
31 target = $$replace(target, /, \\)
32 !isEqual(source,$$target) {
33 !isEmpty(copyCommand):copyCommand += &&
34 isEqual(QMAKE_DIR_SEP, \\) {
35 copyCommand += $(COPY_DIR) \"$$source\" \"$$target\"
37 source = $$replace(source, \\\\, /)
38 target = $$OUT_PWD/$$eval($${deploymentfolder}.target)
39 target = $$replace(target, \\\\, /)
40 copyCommand += test -d \"$$target\" || mkdir -p \"$$target\" && cp -r \"$$source\" \"$$target\"
44 !isEmpty(copyCommand) {
45 copyCommand = @echo Copying application data... && $$copyCommand
46 copydeploymentfolders.commands = $$copyCommand
47 first.depends = $(first) copydeploymentfolders
49 export(copydeploymentfolders.commands)
50 QMAKE_EXTRA_TARGETS += first copydeploymentfolders
54 desktopfile.path = /usr/share/applications/hildon
56 desktopfile.path = /usr/share/applications
58 for(deploymentfolder, DEPLOYMENTFOLDERS) {
59 source = $$MAINPROFILEPWD/$$eval($${deploymentfolder}.source)
60 source = $$replace(source, \\\\, /)
62 target = $$OUT_PWD/$${TARGET}.app/Contents/Resources/$$eval($${deploymentfolder}.target)
64 target = $$OUT_PWD/$$eval($${deploymentfolder}.target)
66 target = $$replace(target, \\\\, /)
67 sourcePathSegments = $$split(source, /)
68 targetFullPath = $$target/$$last(sourcePathSegments)
69 !isEqual(source,$$targetFullPath) {
70 !isEmpty(copyCommand):copyCommand += &&
71 copyCommand += $(MKDIR) \"$$target\"
72 copyCommand += && $(COPY_DIR) \"$$source\" \"$$target\"
75 !isEmpty(copyCommand) {
76 copyCommand = @echo Copying application data... && $$copyCommand
77 copydeploymentfolders.commands = $$copyCommand
78 first.depends = $(first) copydeploymentfolders
80 export(copydeploymentfolders.commands)
81 QMAKE_EXTRA_TARGETS += first copydeploymentfolders
84 installPrefix = /opt/$${TARGET}
85 for(deploymentfolder, DEPLOYMENTFOLDERS) {
86 item = item$${deploymentfolder}
87 itemfiles = $${item}.files
88 $$itemfiles = $$eval($${deploymentfolder}.source)
89 itempath = $${item}.path
90 $$itempath = $${installPrefix}/$$eval($${deploymentfolder}.target)
95 icon.files = $${TARGET}.png
96 icon.path = /usr/share/icons/hicolor/64x64/apps
97 desktopfile.files = $${TARGET}.desktop
98 target.path = $${installPrefix}/bin
101 export(desktopfile.files)
102 export(desktopfile.path)
104 INSTALLS += desktopfile icon target
110 export (TARGET.EPOCHEAPSIZE)
111 export (TARGET.CAPABILITY)
113 export (QMAKE_EXTRA_TARGETS)