summaryrefslogtreecommitdiffstats
path: root/mkspecs/features
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@digia.com>2010-11-05 14:45:39 (GMT)
committerMiikka Heikkinen <miikka.heikkinen@digia.com>2010-11-08 09:51:37 (GMT)
commit70770a2e4fc7581f56a39f7b8b89dd5782cd29c0 (patch)
tree144770f9ffa940b46648c9f47f52b790bd390639 /mkspecs/features
parente8b10f2239a15e8d0ad1b676b7f03d03543efc67 (diff)
downloadQt-70770a2e4fc7581f56a39f7b8b89dd5782cd29c0.zip
Qt-70770a2e4fc7581f56a39f7b8b89dd5782cd29c0.tar.gz
Qt-70770a2e4fc7581f56a39f7b8b89dd5782cd29c0.tar.bz2
Make default application deployment removable
Default application deployment was hard coded in qmake, so it was impossible to replace with custom deployment. Now the default deployment is generated via .prf files and is removable. Cherry picked to 4.7 branch from master branch as part of QTBUG-15068, original commit: 494ce0dac35c7ade0ce78589878597a7ca912864 Task-number: QTBUG-15068 Task-number: QTBUG-13367 Reviewed-by: axis Conflicts: qmake/generators/symbian/symbiancommon.cpp
Diffstat (limited to 'mkspecs/features')
-rw-r--r--mkspecs/features/symbian/application_icon.prf49
-rw-r--r--mkspecs/features/symbian/default_post.prf9
2 files changed, 39 insertions, 19 deletions
diff --git a/mkspecs/features/symbian/application_icon.prf b/mkspecs/features/symbian/application_icon.prf
index 9a9395a..39f10fb 100644
--- a/mkspecs/features/symbian/application_icon.prf
+++ b/mkspecs/features/symbian/application_icon.prf
@@ -1,21 +1,39 @@
load(data_caging_paths)
-# If no_icon keyword exist, the S60 UI app is just made hidden. This because S60 app FW
-# requires the registration resource file to exist always
-contains( CONFIG, no_icon ) {
- symbian:RSS_RULES += "hidden = KAppIsHidden;"
- CONFIG -= no_icon
-} else {
-# There is no point in compiling the MIF icon if no_icon CONFIGS is set
- !isEmpty(ICON) {
+contains(CONFIG, no_icon) {
+ # If no_icon keyword exist, the S60 UI app is just made hidden. This because S60 app FW
+ # requires the registration resource file to exist always
+ contains(QT, gui):contains(CONFIG, qt) {
+ symbian:RSS_RULES += "hidden = KAppIsHidden;"
+ CONFIG -= no_icon
+ }
+}
+
+!contains(CONFIG, no_icon) {
+ baseTarget = $$symbianRemoveSpecialCharacters($$basename(TARGET))
+ symbian-abld|symbian-sbsv2 {
+ resourceZDir = $$EPOCROOT$$HW_ZDIR$$APP_RESOURCE_DIR
+ regZDir = $$EPOCROOT$$HW_ZDIR$$REG_RESOURCE_IMPORT_DIR
+ } else {
+ isEmpty(DESTDIR) {
+ resourceZDir = .
+ } else {
+ resourceZDir = $$DESTDIR
+ }
+ regZDir = $$resourceZDir
+ }
+ default_resource_deployment.sources += $$resourceZDir/$${baseTarget}.rsc
+ default_resource_deployment.path = $$APP_RESOURCE_DIR
+ default_reg_deployment.sources += $$regZDir/$${baseTarget}_reg.rsc
+ default_reg_deployment.path = $$REG_RESOURCE_IMPORT_DIR
+
+ !isEmpty(ICON) {
!count(ICON, 1) {
ICON = $$first(ICON)
warning("Only first icon specified in ICON variable is used: $$ICON")
}
- baseTarget = $$symbianRemoveSpecialCharacters($$basename(TARGET))
-
# Note: symbian-sbsv2 builds can't utilize extra compiler for mifconv, so ICON handling is done in code
!symbian-sbsv2 {
# Absolute path required for shadow builds.
@@ -27,13 +45,10 @@ contains( CONFIG, no_icon ) {
ICON_backslashed = $$ICON
symbian-abld {
+ # ${ZDIR} is defined in Makefile
mifIconZDir = ${ZDIR}$$APP_RESOURCE_DIR
} else {
- isEmpty(DESTDIR) {
- mifIconZDir = .
- } else {
- mifIconZDir = $$DESTDIR
- }
+ mifIconZDir = $$resourceZDir
}
# Extra compiler rules for mifconv
@@ -54,5 +69,9 @@ contains( CONFIG, no_icon ) {
# Rules to use generated MIF file from symbian resources
RSS_RULES.number_of_icons = $$size(ICON_backslashed)
RSS_RULES.icon_file = $$APP_RESOURCE_DIR/$${baseTarget}.mif
+
+ default_resource_deployment.sources += $$resourceZDir/$${baseTarget}.mif
}
}
+
+
diff --git a/mkspecs/features/symbian/default_post.prf b/mkspecs/features/symbian/default_post.prf
index 0564e9b..362bd6c 100644
--- a/mkspecs/features/symbian/default_post.prf
+++ b/mkspecs/features/symbian/default_post.prf
@@ -9,6 +9,11 @@ contains(TEMPLATE, ".*app") {
} else {
QMAKE_LIBS += $$QMAKE_LIBS_QT_ENTRY
}
+
+ default_bin_deployment.sources += $$symbianRemoveSpecialCharacters($$basename(TARGET)).exe
+ default_bin_deployment.path += /sys/bin
+
+ load(application_icon.prf)
}
contains(TEMPLATE, lib): {
contains(CONFIG, staticlib)|contains(CONFIG, static): {
@@ -26,10 +31,6 @@ contains(TEMPLATE, lib): {
MMP_RULES -= EXPORTUNFROZEN
}
-contains(TEMPLATE, ".*app"):contains(QT, gui):contains(CONFIG,qt) {
- load(application_icon.prf)
-}
-
isEmpty(TARGET.UID3):TARGET.UID3 = $$generate_uid("$${OUT_PWD}/$${TARGET}")
isEmpty(TARGET.UID2) {
contains(CONFIG, stdbinary) {