diff options
author | axis <qt-info@nokia.com> | 2010-03-16 16:08:18 (GMT) |
---|---|---|
committer | axis <qt-info@nokia.com> | 2010-03-16 16:08:18 (GMT) |
commit | 567fbee08643fb21e4c36640f36ee6e056e45605 (patch) | |
tree | b79b66da6410af813271ee9b3f9f0ee19622f23b /mkspecs | |
parent | 38c58afc2cc67b8d4d928d734932aa25dfd367e2 (diff) | |
download | Qt-567fbee08643fb21e4c36640f36ee6e056e45605.zip Qt-567fbee08643fb21e4c36640f36ee6e056e45605.tar.gz Qt-567fbee08643fb21e4c36640f36ee6e056e45605.tar.bz2 |
Removed a warning about generated rss files.
Also cleaned up the "clean" and "distclean" targets a bit.
Task: QTBUG-8854
Diffstat (limited to 'mkspecs')
-rw-r--r-- | mkspecs/features/symbian/application_icon.prf | 16 | ||||
-rw-r--r-- | mkspecs/features/symbian/symbian_building.prf | 65 |
2 files changed, 53 insertions, 28 deletions
diff --git a/mkspecs/features/symbian/application_icon.prf b/mkspecs/features/symbian/application_icon.prf index 04560c5..1109060 100644 --- a/mkspecs/features/symbian/application_icon.prf +++ b/mkspecs/features/symbian/application_icon.prf @@ -32,7 +32,8 @@ contains( CONFIG, no_icon ) { # Note: symbian-sbsv2 builds can't utilize extra compiler for mifconv, so ICON handling is done in code !symbian-sbsv2 { #Makefile: requires paths with backslash - ICON_backslashed = $$replace( ICON, /, \\) + ICON_backslashed = $$ICON + contains(QMAKE_HOST.os, "Windows"):ICON_backslashed = $$replace( ICON_backslashed, /, \\) symbian-abld { mifIconZDir = ${ZDIR}$$APP_RESOURCE_DIR @@ -45,15 +46,14 @@ contains( CONFIG, no_icon ) { } # Extra compiler rules for mifconv - mifconv.output = $$mifIconZDir/$${baseTarget}.mif + mifconv.target = $$mifIconZDir/$${baseTarget}.mif # Based on: http://www.forum.nokia.com/document/Cpp_Developers_Library # svg-t icons should always use /c32 depth - mifconv.commands = mifconv ${QMAKE_FILE_OUT} /c32 ${QMAKE_FILE_IN} - mifconv.input = ICON_backslashed - mifconv.CONFIG = no_link combine - # target_predeps together with combine seems not to work correctly, lets define it by ourselves - PRE_TARGETDEPS += $$mifconv.output - QMAKE_EXTRA_COMPILERS += mifconv + mifconv.commands = mifconv $$mifconv.target /c32 $$ICON_backslashed + mifconv.depends = $$ICON + PRE_TARGETDEPS += $$mifconv.target + QMAKE_EXTRA_TARGETS += mifconv + QMAKE_DISTCLEAN += $$mifconv.target } # Rules to use generated MIF file from symbian resources RSS_RULES.number_of_icons = $$size(ICON_backslashed) diff --git a/mkspecs/features/symbian/symbian_building.prf b/mkspecs/features/symbian/symbian_building.prf index b543587..aae7e39 100644 --- a/mkspecs/features/symbian/symbian_building.prf +++ b/mkspecs/features/symbian/symbian_building.prf @@ -212,28 +212,53 @@ contains(TEMPLATE, "app"):!contains(CONFIG, "no_icon") { # If you change this, also see application_icon.prf baseTarget = $$replace(baseTarget, " ",_) - # Make our own extra compiler target in order to get dependencies for generated + # Make our own extra target in order to get dependencies for generated # files right. This also avoids the warning about files not found. - symbianGenResource.inputFile = $${baseTarget}.rss - symbianGenResource.input = symbianGenResource.inputFile - # Reuse the command from earlier. - symbianGenResource.commands = $$symbianresources.commands - symbianGenResource.output = $$symbianresources.output - symbianGenResource.CONFIG = no_link target_predeps - - symbianGenRegResource.inputFile = $${baseTarget}_reg.rss - symbianGenRegResource.input = symbianGenRegResource.inputFile - symbianGenRegResource.commands = $$symbianresources.commands - symbianGenRegResource.output = $$symbianresources.output - symbianGenRegResource.CONFIG = no_link target_predeps - symbianGenRegResource.depends = $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg - - QMAKE_EXTRA_COMPILERS += symbianGenResource symbianGenRegResource - - QMAKE_DISTCLEAN += $${TARGET}.rss - QMAKE_DISTCLEAN += $${TARGET}.rsc + symbianGenResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg + symbianGenResource.commands = cpp -nostdinc -undef \ + $$symbian_resources_INCLUDES \ + $$symbian_resources_DEFINES \ + $${baseTarget}.rss \ + -o $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp \ + && rcomp -u -m045,046,047 \ + -s$${symbian_resources_RCC_DIR}/$${baseTarget}.rpp \ + -o$${symbianDestdir}/$${baseTarget}.rsc \ + -h$${symbian_resources_RCC_DIR}/$${baseTarget}.rsg \ + -i$${baseTarget}.rss + symbianGenResource.depends = $${baseTarget}.rss + PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg + QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg + QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp + QMAKE_DISTCLEAN += $${baseTarget}.rss + QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.rsc + + symbianGenRegResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg + symbianGenRegResource.commands = cpp -nostdinc -undef \ + $$symbian_resources_INCLUDES \ + $$symbian_resources_DEFINES \ + $${baseTarget}_reg.rss \ + -o $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp \ + && rcomp -u -m045,046,047 \ + -s$${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp \ + -o$${symbianDestdir}/$${baseTarget}_reg.rsc \ + -h$${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg \ + -i$${baseTarget}_reg.rss + symbianGenRegResource.depends = $${baseTarget}_reg.rss $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg + PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg + QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg + QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp QMAKE_DISTCLEAN += $${TARGET}_reg.rss - QMAKE_DISTCLEAN += $${TARGET}_reg.rsc + QMAKE_DISTCLEAN += $${symbianDestdir}/$${TARGET}_reg.rsc + + # Trick to get qmake to create the RCC_DIR for us. + symbianRccDirCreation.input = SOURCES + symbianRccDirCreation.commands = + symbianRccDirCreation.output = $${symbian_resources_RCC_DIR}/symbian_resource_dummy + symbianRccDirCreation.CONFIG = no_link combine + + QMAKE_EXTRA_TARGETS += symbianGenResource symbianGenRegResource + QMAKE_EXTRA_COMPILERS += symbianRccDirCreation + QMAKE_DISTCLEAN += $${TARGET}.loc } |