summaryrefslogtreecommitdiffstats
path: root/mkspecs
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@digia.com>2011-01-27 10:40:33 (GMT)
committerJason McDonald <jason.mcdonald@nokia.com>2011-01-31 13:06:43 (GMT)
commit884dc710553c44277504245dc908f96731da84ed (patch)
tree19777fa18f0adab84d8ee4e9ad1a860fe6eb3e82 /mkspecs
parentc403773accc3b3e9d90df54663efa6f5ff116bee (diff)
downloadQt-884dc710553c44277504245dc908f96731da84ed.zip
Qt-884dc710553c44277504245dc908f96731da84ed.tar.gz
Qt-884dc710553c44277504245dc908f96731da84ed.tar.bz2
No longer replace dash and dot in TARGET with underscore in Symbian
There is no fundamental reason to not have dash or dot in binary names in Symbian, so do not replace them with underscore. One thing that doesn't work with a dot in the filename is launching an application via resources, so automatic resource generation is suppressed for applications that have a dot in filename portion of the TARGET value. Task-number: QTBUG-16888 Reviewed-by: axis (cherry picked from commit 4ec245a3e75470186557d00b2383af3872a720b0)
Diffstat (limited to 'mkspecs')
-rw-r--r--mkspecs/common/symbian/symbian.conf9
-rw-r--r--mkspecs/features/symbian/application_icon.prf106
2 files changed, 58 insertions, 57 deletions
diff --git a/mkspecs/common/symbian/symbian.conf b/mkspecs/common/symbian/symbian.conf
index 00cf0d7..f8473ed 100644
--- a/mkspecs/common/symbian/symbian.conf
+++ b/mkspecs/common/symbian/symbian.conf
@@ -212,19 +212,14 @@ default_deployment.pkg_prerules += pkg_depends_webkit pkg_depends_qt pkg_platfor
DEPLOYMENT += default_deployment default_bin_deployment default_resource_deployment default_reg_deployment
defineReplace(symbianRemoveSpecialCharacters) {
- # Produce identical string to what SymbianCommonGenerator::removeSpecialCharacters and
- # SymbianCommonGenerator::removeEpocSpecialCharacters produce
+ # Produce identical string to what SymbianCommonGenerator::removeSpecialCharacters
fixedStr = $$1
fixedStr = $$replace(fixedStr, /,_)
fixedStr = $$replace(fixedStr, \\\\,_)
fixedStr = $$replace(fixedStr, " ",_)
- symbian-abld|symbian-sbsv2 {
- fixedStr = $$replace(fixedStr, -,_)
- fixedStr = $$replace(fixedStr, \\.,_)
- fixedStr = $$replace(fixedStr, :,_)
- }
+ fixedStr = $$replace(fixedStr, :,_)
return ($$fixedStr)
}
diff --git a/mkspecs/features/symbian/application_icon.prf b/mkspecs/features/symbian/application_icon.prf
index 6e1aa8e..b6be89b 100644
--- a/mkspecs/features/symbian/application_icon.prf
+++ b/mkspecs/features/symbian/application_icon.prf
@@ -11,68 +11,74 @@ contains(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
+ contains(baseTarget, "^.*\\..*$") {
+ CONFIG += no_icon
+ ICON =
+ warning("Symbian resources do not support '.' character in TARGET, skipping resource generation.")
} else {
- contains(DESTDIR, "/.*") {
- resourceZDir = $$DESTDIR
- } else:isEmpty(DESTDIR) {
- resourceZDir = $$OUT_PWD
+ symbian-abld|symbian-sbsv2 {
+ resourceZDir = $$EPOCROOT$$HW_ZDIR$$APP_RESOURCE_DIR
+ regZDir = $$EPOCROOT$$HW_ZDIR$$REG_RESOURCE_IMPORT_DIR
} else {
- resourceZDir = $$OUT_PWD/$$DESTDIR
+ contains(DESTDIR, "/.*") {
+ resourceZDir = $$DESTDIR
+ } else:isEmpty(DESTDIR) {
+ resourceZDir = $$OUT_PWD
+ } else {
+ resourceZDir = $$OUT_PWD/$$DESTDIR
+ }
+ regZDir = $$resourceZDir
}
- 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
+ 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")
- }
+ !isEmpty(ICON) {
+ !count(ICON, 1) {
+ ICON = $$first(ICON)
+ warning("Only first icon specified in ICON variable is used: $$ICON")
+ }
- # 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.
- # However, in older Symbian environments abld toolchain can't handle even moderately long
- # paths, so don't force absolute there.
- !symbian-abld:!contains(ICON, "^(/|\\\\|.:).*"):ICON = $$_PRO_FILE_PWD_/$$ICON
+ # 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.
+ # However, in older Symbian environments abld toolchain can't handle even moderately long
+ # paths, so don't force absolute there.
+ !symbian-abld:!contains(ICON, "^(/|\\\\|.:).*"):ICON = $$_PRO_FILE_PWD_/$$ICON
- #Makefile: requires paths with backslash
- ICON_backslashed = $$ICON
+ #Makefile: requires paths with backslash
+ ICON_backslashed = $$ICON
- symbian-abld {
- # ${ZDIR} is defined in Makefile
- mifIconZDir = ${ZDIR}$$APP_RESOURCE_DIR
- } else {
- mifIconZDir = $$resourceZDir
- }
+ symbian-abld {
+ # ${ZDIR} is defined in Makefile
+ mifIconZDir = ${ZDIR}$$APP_RESOURCE_DIR
+ } else {
+ mifIconZDir = $$resourceZDir
+ }
- # Extra compiler rules for mifconv
- mifconv.target = $$mifIconZDir/$${baseTarget}.mif
- contains(QMAKE_HOST.os, "Windows") {
- ICON_backslashed = $$replace(ICON_backslashed, /, \\)
- mifconv.target = $$replace(mifconv.target, /, \\)
+ # Extra compiler rules for mifconv
+ mifconv.target = $$mifIconZDir/$${baseTarget}.mif
+ contains(QMAKE_HOST.os, "Windows") {
+ ICON_backslashed = $$replace(ICON_backslashed, /, \\)
+ mifconv.target = $$replace(mifconv.target, /, \\)
+ }
+ # Based on: http://www.forum.nokia.com/document/Cpp_Developers_Library
+ # svg-t icons should always use /c32 depth
+ mifconv.commands = mifconv $$mifconv.target /c32 $$ICON_backslashed
+
+ mifconv.depends = $$ICON
+ PRE_TARGETDEPS += $$mifconv.target
+ QMAKE_EXTRA_TARGETS += mifconv
+ QMAKE_DISTCLEAN += $$mifconv.target
}
- # Based on: http://www.forum.nokia.com/document/Cpp_Developers_Library
- # svg-t icons should always use /c32 depth
- mifconv.commands = mifconv $$mifconv.target /c32 $$ICON_backslashed
+ # 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
- mifconv.depends = $$ICON
- PRE_TARGETDEPS += $$mifconv.target
- QMAKE_EXTRA_TARGETS += mifconv
- QMAKE_DISTCLEAN += $$mifconv.target
+ default_resource_deployment.sources += $$resourceZDir/$${baseTarget}.mif
}
- # 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
}
}