summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mkspecs/features/sis_targets.prf25
-rw-r--r--mkspecs/features/symbian/symbian_building.prf104
2 files changed, 66 insertions, 63 deletions
diff --git a/mkspecs/features/sis_targets.prf b/mkspecs/features/sis_targets.prf
index 4207e0b..c31e38f 100644
--- a/mkspecs/features/sis_targets.prf
+++ b/mkspecs/features/sis_targets.prf
@@ -126,35 +126,38 @@ equals(GENERATE_SIS_TARGETS, true) {
}
} else {
sis_destdir = $$DESTDIR
- !isEmpty(sis_destdir):!contains(sis_destdir, "[/\\\\]$"):sis_destdir = $${sis_destdir}/
- contains(QMAKE_HOST.os, "Windows"):sis_destdir = $$replace(sis_destdir, "/", "\\")
+ isEmpty(sis_destdir):sis_destdir = .
+ baseTarget = $$basename(TARGET)
+ !equals(TARGET, "$$baseTarget"):sis_destdir = $$sis_destdir/$$dirname(TARGET)
sis_target.target = sis
- sis_target.commands = createpackage $(QT_SIS_OPTIONS) $$basename(TARGET)_template.pkg \
+ sis_target.commands = createpackage $(QT_SIS_OPTIONS) $${baseTarget}_template.pkg \
- $(QT_SIS_CERTIFICATE) $(QT_SIS_KEY) $(QT_SIS_PASSPHRASE)
sis_target.depends = first
unsigned_sis_target.target = unsigned_sis
- unsigned_sis_target.commands = createpackage $(QT_SIS_OPTIONS) -o $$basename(TARGET)_template.pkg
+ unsigned_sis_target.commands = createpackage $(QT_SIS_OPTIONS) -o $${baseTarget}_template.pkg
unsigned_sis_target.depends = first
- target_sis_target.target = $${sis_destdir}$${TARGET}.sis
+ target_sis_target.target = $${sis_destdir}/$${baseTarget}.sis
target_sis_target.commands = $(MAKE) -f $(MAKEFILE) sis
installer_sis_target.target = installer_sis
- installer_sis_target.commands = createpackage $(QT_SIS_OPTIONS) $$basename(TARGET)_installer.pkg - \
+ installer_sis_target.commands = createpackage $(QT_SIS_OPTIONS) $${baseTarget}_installer.pkg - \
$(QT_SIS_CERTIFICATE) $(QT_SIS_KEY) $(QT_SIS_PASSPHRASE)
- installer_sis_target.depends = $${sis_destdir}$${TARGET}.sis
+ installer_sis_target.depends = $${sis_destdir}/$${baseTarget}.sis
- !isEmpty(DESTDIR) {
- sis_target.commands += && $$QMAKE_MOVE $$basename(TARGET).sis $$DESTDIR
- installer_sis_target.commands += && $$QMAKE_MOVE $$basename(TARGET).sis $$DESTDIR
+ !isEmpty(sis_destdir):!equals(sis_destdir, "."):!equals(sis_destdir, "./") {
+ sis_target.commands += && $$QMAKE_MOVE $${baseTarget}.sis $$sis_destdir
+ installer_sis_target.commands += && $$QMAKE_MOVE $${baseTarget}.sis $$sis_destdir
}
QMAKE_EXTRA_TARGETS += sis_target \
unsigned_sis_target \
target_sis_target \
installer_sis_target
+
+ QMAKE_DISTCLEAN += $${sis_destdir}/$${baseTarget}.sis
}
} else {
contains(TEMPLATE, subdirs) {
@@ -177,5 +180,3 @@ equals(GENERATE_SIS_TARGETS, true) {
QMAKE_EXTRA_TARGETS += store_build_target
}
}
-
-QMAKE_DISTCLEAN += $${sis_destdir}$${TARGET}.sis
diff --git a/mkspecs/features/symbian/symbian_building.prf b/mkspecs/features/symbian/symbian_building.prf
index 08ab3e7..744580f 100644
--- a/mkspecs/features/symbian/symbian_building.prf
+++ b/mkspecs/features/symbian/symbian_building.prf
@@ -21,6 +21,8 @@ symbianDestdir=$$DESTDIR
isEmpty(symbianDestdir) {
symbianDestdir = .
}
+baseTarget = $$basename(TARGET)
+!equals(TARGET, "$$baseTarget"):symbianDestdir = $$symbianDestdir/$$dirname(TARGET)
contains(QMAKE_CFLAGS, "--thumb")|contains(QMAKE_CXXFLAGS, "--thumb")|contains(QMAKE_CFLAGS, "-mthumb")|contains(QMAKE_CXXFLAGS, "-mthumb") {
DEFINES += __MARM_THUMB__
@@ -107,29 +109,29 @@ contains(TEMPLATE, lib):!contains(CONFIG, static):!contains(CONFIG, staticlib) {
# The tee and grep at the end work around the issue that elf2e32 doesn't return non-null on error.
# The comparison of dso files is to avoid extra building of modules that depend on this dso, in
# case it has not changed.
- QMAKE_POST_LINK = $$QMAKE_MOVE $$symbianDestdir/$${TARGET}.dll $$symbianDestdir/$${TARGET}.sym \
+ QMAKE_POST_LINK = $$QMAKE_MOVE $$symbianDestdir/$${baseTarget}.dll $$symbianDestdir/$${baseTarget}.sym \
&& elf2e32_qtwrapper --version=$$decVersion \
--sid=$$TARGET.SID \
--uid1=0x10000079 \
--uid2=$$TARGET.UID2 \
--uid3=$$TARGET.UID3 \
--targettype=DLL \
- --elfinput=$${symbianDestdir}/$${TARGET}.sym \
- --output=$${symbianDestdir}/$${TARGET}.dll \
- --tmpdso=$${symbianObjdir}/$${TARGET}.dso \
- --dso=$${symbianDestdir}/$${TARGET}.dso \
- --defoutput=$$symbianObjdir/$${TARGET}.def \
- --linkas=$${TARGET}\\{$${hexVersion}\\}\\[$${intUid3}\\].dll \
+ --elfinput=$${symbianDestdir}/$${baseTarget}.sym \
+ --output=$${symbianDestdir}/$${baseTarget}.dll \
+ --tmpdso=$${symbianObjdir}/$${baseTarget}.dso \
+ --dso=$${symbianDestdir}/$${baseTarget}.dso \
+ --defoutput=$$symbianObjdir/$${baseTarget}.def \
+ --linkas=$${baseTarget}\\{$${hexVersion}\\}\\[$${intUid3}\\].dll \
--heap=$$epoc_heap_size \
--stack=$$TARGET.EPOCSTACKSIZE \
$$elf2e32_LIBPATH \
$$capability \
$$QMAKE_ELF2E32_FLAGS \
$$QMAKE_POST_LINK
- QMAKE_DISTCLEAN += $${symbianDestdir}/$${TARGET}.sym
- QMAKE_DISTCLEAN += $${symbianDestdir}/$${TARGET}.dso
- QMAKE_CLEAN += $${symbianObjdir}/$${TARGET}.dso
- QMAKE_CLEAN += $${symbianObjdir}/$${TARGET}.def
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.sym
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.dso
+ QMAKE_CLEAN += $${symbianObjdir}/$${baseTarget}.dso
+ QMAKE_CLEAN += $${symbianObjdir}/$${baseTarget}.def
linux-armcc: {
LIBS += usrt2_2.lib dfpaeabi.dso dfprvct2_2.dso drtaeabi.dso scppnwdl.dso drtrvct2_2.dso h_t__uf.l\\(switch8.o\\)
@@ -145,7 +147,7 @@ contains(TEMPLATE, lib):!contains(CONFIG, static):!contains(CONFIG, staticlib) {
-lgcc
}
- QMAKE_LFLAGS += --soname $${TARGET}\\{$${hexVersion}\\}\\[$${intUid3}\\].dll
+ QMAKE_LFLAGS += --soname $${baseTarget}\\{$${hexVersion}\\}\\[$${intUid3}\\].dll
DEFINES += __DLL__
}
@@ -156,26 +158,26 @@ contains(TEMPLATE, app):!contains(QMAKE_LINK, "^@.*") {
QMAKE_POST_LINK = && $$QMAKE_POST_LINK
}
# the tee and grep at the end work around the issue that elf2e32 doesn't return non-null on error
- QMAKE_POST_LINK = $$QMAKE_MOVE $$symbianDestdir/$${TARGET} $$symbianDestdir/$${TARGET}.sym \
+ QMAKE_POST_LINK = $$QMAKE_MOVE $$symbianDestdir/$${baseTarget} $$symbianDestdir/$${baseTarget}.sym \
&& elf2e32_qtwrapper --version $$decVersion \
--sid=$$TARGET.SID \
--uid1=0x1000007a \
--uid2=$$TARGET.UID2 \
--uid3=$$TARGET.UID3 \
--targettype=EXE \
- --elfinput=$${symbianDestdir}/$${TARGET}.sym \
- --output=$${symbianDestdir}/$${TARGET}.exe \
- --linkas=$${TARGET}\\{$${hexVersion}\\}\\[$${intUid3}\\].exe \
+ --elfinput=$${symbianDestdir}/$${baseTarget}.sym \
+ --output=$${symbianDestdir}/$${baseTarget}.exe \
+ --linkas=$${baseTarget}\\{$${hexVersion}\\}\\[$${intUid3}\\].exe \
--heap=$$epoc_heap_size \
--stack=$$TARGET.EPOCSTACKSIZE \
$$elf2e32_LIBPATH \
$$capability \
$$QMAKE_ELF2E32_FLAGS \
- && ln "$${symbianDestdir}/$${TARGET}.exe" "$${symbianDestdir}/$$TARGET" \
+ && ln "$${symbianDestdir}/$${baseTarget}.exe" "$${symbianDestdir}/$${baseTarget}" \
$$QMAKE_POST_LINK
- QMAKE_DISTCLEAN += $${symbianDestdir}/$${TARGET}.sym
- QMAKE_DISTCLEAN += $${symbianDestdir}/$${TARGET}.exe
- QMAKE_CLEAN += $${symbianDestdir}/$${TARGET}
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.sym
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.exe
+ QMAKE_CLEAN += $${symbianDestdir}/$${baseTarget}
linux-armcc: {
QMAKE_LIBS += usrt2_2.lib dfpaeabi.dso dfprvct2_2.dso drtaeabi.dso scppnwdl.dso drtrvct2_2.dso h_t__uf.l\\(switch8.o\\)
@@ -204,7 +206,7 @@ contains(TEMPLATE, app):!contains(QMAKE_LINK, "^@.*") {
QMAKE_LFLAGS += --shared
}
- QMAKE_LFLAGS += --soname $${TARGET}\\{$${hexVersion}\\}\\[$${intUid3}\\].exe
+ QMAKE_LFLAGS += --soname $${baseTarget}\\{$${hexVersion}\\}\\[$${intUid3}\\].exe
DEFINES += __EXE__
}
@@ -245,47 +247,47 @@ symbianresources.CONFIG = no_link target_predeps
QMAKE_EXTRA_COMPILERS += symbianresources
contains(TEMPLATE, "app"):!contains(CONFIG, "no_icon") {
- baseTarget = $$basename(TARGET)
+ baseResourceTarget = $$basename(TARGET)
# If you change this, also see application_icon.prf
- baseTarget = $$replace(baseTarget, " ",_)
+ baseResourceTarget = $$replace(baseResourceTarget, " ",_)
# Make our own extra target in order to get dependencies for generated
# files right. This also avoids the warning about files not found.
- symbianGenResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg
+ symbianGenResource.target = $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rsg
symbianGenResource.commands = cpp -nostdinc -undef \
$$symbian_resources_INCLUDES \
$$symbian_resources_DEFINES \
- $${baseTarget}.rss \
- -o $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp \
+ $${baseResourceTarget}.rss \
+ -o $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.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
+ -s$${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rpp \
+ -o$${symbianDestdir}/$${baseResourceTarget}.rsc \
+ -h$${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rsg \
+ -i$${baseResourceTarget}.rss
+ symbianGenResource.depends = $${baseResourceTarget}.rss
+ PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rsg
+ QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rsg
+ QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rpp
+ QMAKE_DISTCLEAN += $${baseResourceTarget}.rss
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseResourceTarget}.rsc
- symbianGenRegResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg
+ symbianGenRegResource.target = $${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rsg
symbianGenRegResource.commands = cpp -nostdinc -undef \
$$symbian_resources_INCLUDES \
$$symbian_resources_DEFINES \
- $${baseTarget}_reg.rss \
- -o $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp \
+ $${baseResourceTarget}_reg.rss \
+ -o $${symbian_resources_RCC_DIR}/$${baseResourceTarget}_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 += $${symbianDestdir}/$${TARGET}_reg.rsc
+ -s$${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rpp \
+ -o$${symbianDestdir}/$${baseResourceTarget}_reg.rsc \
+ -h$${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rsg \
+ -i$${baseResourceTarget}_reg.rss
+ symbianGenRegResource.depends = $${baseResourceTarget}_reg.rss $${symbian_resources_RCC_DIR}/$${baseResourceTarget}.rsg
+ PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rsg
+ QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rsg
+ QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseResourceTarget}_reg.rpp
+ QMAKE_DISTCLEAN += $${baseResourceTarget}_reg.rss
+ QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseResourceTarget}_reg.rsc
# Trick to get qmake to create the RCC_DIR for us.
symbianRccDirCreation.input = SOURCES
@@ -296,9 +298,9 @@ contains(TEMPLATE, "app"):!contains(CONFIG, "no_icon") {
QMAKE_EXTRA_TARGETS += symbianGenResource symbianGenRegResource
QMAKE_EXTRA_COMPILERS += symbianRccDirCreation
- QMAKE_DISTCLEAN += $${TARGET}.loc
+ QMAKE_DISTCLEAN += $${baseTarget}.loc
}
# Generated pkg files
-QMAKE_DISTCLEAN += $${TARGET}_template.pkg
+QMAKE_DISTCLEAN += $${baseTarget}_template.pkg