Work in progress: hacks at vienna, do not use it
[googlelatitude] / deployment.pri
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.
6
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)
14     export($$itemsources)
15     export($$itempath)
16     DEPLOYMENT += $$item
17 }
18
19 MAINPROFILEPWD = $$PWD
20
21 symbian {
22     isEmpty(ICON):exists($${TARGET}.svg):ICON = $${TARGET}.svg
23     isEmpty(TARGET.EPOCHEAPSIZE):TARGET.EPOCHEAPSIZE = 0x20000 0x2000000
24 } else:win32 {
25     copyCommand =
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\"
36             } else {
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\"
41             }
42         }
43     }
44     !isEmpty(copyCommand) {
45         copyCommand = @echo Copying application data... && $$copyCommand
46         copydeploymentfolders.commands = $$copyCommand
47         first.depends = $(first) copydeploymentfolders
48         export(first.depends)
49         export(copydeploymentfolders.commands)
50         QMAKE_EXTRA_TARGETS += first copydeploymentfolders
51     }
52 } else:unix {
53     maemo5 {
54         desktopfile.files = $${TARGET}_fremantle.desktop
55         desktopfile.path = /usr/share/applications/hildon
56         icon.files = $${TARGET}64.png
57         icon.path = /usr/share/icons/hicolor/64x64/apps
58     } else:!isEmpty(MEEGO_VERSION_MAJOR) {
59         desktopfile.files = $${TARGET}_harmattan.desktop
60         desktopfile.path = /usr/share/applications
61         icon.files = $${TARGET}80.png
62         icon.path = /usr/share/icons/hicolor/80x80/apps
63     } else { # Assumed to be a Desktop Unix
64         copyCommand =
65         for(deploymentfolder, DEPLOYMENTFOLDERS) {
66             source = $$MAINPROFILEPWD/$$eval($${deploymentfolder}.source)
67             source = $$replace(source, \\\\, /)
68             macx {
69                 target = $$OUT_PWD/$${TARGET}.app/Contents/Resources/$$eval($${deploymentfolder}.target)
70             } else {
71                 target = $$OUT_PWD/$$eval($${deploymentfolder}.target)
72             }
73             target = $$replace(target, \\\\, /)
74             sourcePathSegments = $$split(source, /)
75             targetFullPath = $$target/$$last(sourcePathSegments)
76             !isEqual(source,$$targetFullPath) {
77                 !isEmpty(copyCommand):copyCommand += &&
78                 copyCommand += $(MKDIR) \"$$target\"
79                 copyCommand += && $(COPY_DIR) \"$$source\" \"$$target\"
80             }
81         }
82         !isEmpty(copyCommand) {
83             copyCommand = @echo Copying application data... && $$copyCommand
84             copydeploymentfolders.commands = $$copyCommand
85             first.depends = $(first) copydeploymentfolders
86             export(first.depends)
87             export(copydeploymentfolders.commands)
88             QMAKE_EXTRA_TARGETS += first copydeploymentfolders
89         }
90     }
91     installPrefix = /opt/linfati.com
92     for(deploymentfolder, DEPLOYMENTFOLDERS) {
93         item = item$${deploymentfolder}
94         itemfiles = $${item}.files
95         $$itemfiles = $$eval($${deploymentfolder}.source)
96         itempath = $${item}.path
97         $$itempath = $${installPrefix}/$$eval($${deploymentfolder}.target)
98         export($$itemfiles)
99         export($$itempath)
100         INSTALLS += $$item
101     }
102
103     !isEmpty(desktopfile.path) {
104         export(icon.files)
105         export(icon.path)
106         export(desktopfile.files)
107         export(desktopfile.path)
108         INSTALLS += icon desktopfile
109     }
110
111     target.path = $${installPrefix}/bin
112     export(target.path)
113     INSTALLS += target
114 }
115
116 export (ICON)
117 export (INSTALLS)
118 export (DEPLOYMENT)
119 export (TARGET.EPOCHEAPSIZE)
120 export (TARGET.CAPABILITY)
121 export (LIBS)
122 export (QMAKE_EXTRA_TARGETS)
123 }