deployment.pri 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. # checksum 0x2939 version 0x20001
  2. # This file was generated by an application wizard of Qt Creator.
  3. # The code below handles deployment to Symbian and Maemo, aswell as copying
  4. # of the application data to shadow build directories on desktop.
  5. # It is recommended not to modify this file, since newer versions of Qt Creator
  6. # 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)
  14. export($$itemsources)
  15. export($$itempath)
  16. DEPLOYMENT += $$item
  17. }
  18. MAINPROFILEPWD = $$PWD
  19. symbian {
  20. ICON = $${TARGET}.svg
  21. TARGET.EPOCHEAPSIZE = 0x20000 0x2000000
  22. contains(DEFINES, ORIENTATIONLOCK):LIBS += -lavkon -leikcore -lcone
  23. contains(DEFINES, NETWORKACCESS):TARGET.CAPABILITY += NetworkServices
  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. copyCommand += $(COPY_DIR) \"$$source\" \"$$target\"
  35. }
  36. }
  37. !isEmpty(copyCommand) {
  38. copyCommand = @echo Copying application data... && $$copyCommand
  39. copydeploymentfolders.commands = $$copyCommand
  40. first.depends = $(first) copydeploymentfolders
  41. export(first.depends)
  42. export(copydeploymentfolders.commands)
  43. QMAKE_EXTRA_TARGETS += first copydeploymentfolders
  44. }
  45. } else:unix {
  46. maemo5 {
  47. installPrefix = /opt/usr
  48. desktopfile.path = /usr/share/applications/hildon
  49. } else {
  50. installPrefix = /usr/local
  51. desktopfile.path = /usr/share/applications
  52. copyCommand =
  53. for(deploymentfolder, DEPLOYMENTFOLDERS) {
  54. source = $$MAINPROFILEPWD/$$eval($${deploymentfolder}.source)
  55. source = $$replace(source, \\, /)
  56. macx {
  57. target = $$OUT_PWD/$${TARGET}.app/Contents/Resources/$$eval($${deploymentfolder}.target)
  58. } else {
  59. target = $$OUT_PWD/$$eval($${deploymentfolder}.target)
  60. }
  61. target = $$replace(target, \\, /)
  62. sourcePathSegments = $$split(source, /)
  63. targetFullPath = $$target/$$last(sourcePathSegments)
  64. !isEqual(source,$$targetFullPath) {
  65. !isEmpty(copyCommand):copyCommand += &&
  66. copyCommand += $(MKDIR) \"$$target\"
  67. copyCommand += && $(COPY_DIR) \"$$source\" \"$$target\"
  68. }
  69. }
  70. !isEmpty(copyCommand) {
  71. copyCommand = @echo Copying application data... && $$copyCommand
  72. copydeploymentfolders.commands = $$copyCommand
  73. first.depends = $(first) copydeploymentfolders
  74. export(first.depends)
  75. export(copydeploymentfolders.commands)
  76. QMAKE_EXTRA_TARGETS += first copydeploymentfolders
  77. }
  78. }
  79. for(deploymentfolder, DEPLOYMENTFOLDERS) {
  80. item = item$${deploymentfolder}
  81. itemfiles = $${item}.files
  82. $$itemfiles = $$eval($${deploymentfolder}.source)
  83. itempath = $${item}.path
  84. $$itempath = $${installPrefix}/share/$${TARGET}/$$eval($${deploymentfolder}.target)
  85. export($$itemfiles)
  86. export($$itempath)
  87. INSTALLS += $$item
  88. }
  89. icon.files = $${TARGET}.png
  90. icon.path = /usr/share/icons/hicolor/64x64/apps
  91. desktopfile.files = $${TARGET}.desktop
  92. target.path = $${installPrefix}/bin
  93. export(icon.files)
  94. export(icon.path)
  95. export(desktopfile.files)
  96. export(desktopfile.path)
  97. export(target.path)
  98. INSTALLS += desktopfile icon target
  99. }
  100. export (ICON)
  101. export (INSTALLS)
  102. export (DEPLOYMENT)
  103. export (TARGET.EPOCHEAPSIZE)
  104. export (TARGET.CAPABILITY)
  105. export (LIBS)
  106. export (QMAKE_EXTRA_TARGETS)
  107. }