From 8336bbe157618eb062a647d1685e3b4c440b7ec7 Mon Sep 17 00:00:00 2001 From: axis Date: Mon, 8 Nov 2010 15:18:11 +0100 Subject: Started using qtmain.lib for all Qt applications, also corelib ones. This commit also fixes the issue that 564058a1bb didn't, namely that config tests broke on Symbian. It does this by continuing to use the Open C libcrt0.lib library for non-Qt applications. This is also more correct, since you should not have to compile the Qt libs to compile a non-Qt app. Task: QTBUG-14735 RevBy: Miikka Heikkinen --- config.tests/symbian/audio/audio.pro | 1 + config.tests/symbian/simple/simple.pro | 1 + mkspecs/common/symbian/symbian.conf | 2 ++ mkspecs/features/symbian/default_post.prf | 4 +++- mkspecs/features/symbian/symbian_building.prf | 23 ++++++++++++++++++----- 5 files changed, 25 insertions(+), 6 deletions(-) diff --git a/config.tests/symbian/audio/audio.pro b/config.tests/symbian/audio/audio.pro index b2a1986..b496341 100644 --- a/config.tests/symbian/audio/audio.pro +++ b/config.tests/symbian/audio/audio.pro @@ -6,4 +6,5 @@ INCLUDEPATH += $${EPOCROOT}epoc32/include/mmf/common INCLUDEPATH += $${EPOCROOT}epoc32/include/platform LIBS += -lmmfdevsound +CONFIG -= qt QT = diff --git a/config.tests/symbian/simple/simple.pro b/config.tests/symbian/simple/simple.pro index fa086c9..9c60d62 100644 --- a/config.tests/symbian/simple/simple.pro +++ b/config.tests/symbian/simple/simple.pro @@ -1,4 +1,5 @@ TEMPLATE = app +CONFIG -= qt QT = SOURCES += main.cpp diff --git a/mkspecs/common/symbian/symbian.conf b/mkspecs/common/symbian/symbian.conf index dc18db6..4d0320d 100644 --- a/mkspecs/common/symbian/symbian.conf +++ b/mkspecs/common/symbian/symbian.conf @@ -127,6 +127,8 @@ QT_ARCH = symbian load(qt_config) QMAKE_LIBS_QT_ENTRY = -lqtmain$${QT_LIBINFIX}.lib +QMAKE_LIBS_NO_QT_ENTRY = -llibcrt0.lib +QMAKE_LIBS_NO_QT_ENTRY_GCCE = -llibcrt0_gcce.lib # These directories must match what configure uses for QT_INSTALL_PLUGINS and QT_INSTALL_IMPORTS QT_PLUGINS_BASE_DIR = /resource/qt$${QT_LIBINFIX}/plugins diff --git a/mkspecs/features/symbian/default_post.prf b/mkspecs/features/symbian/default_post.prf index 32ba798..fe1f6d3 100644 --- a/mkspecs/features/symbian/default_post.prf +++ b/mkspecs/features/symbian/default_post.prf @@ -3,8 +3,10 @@ load(default_post) contains(TEMPLATE, ".*app") { contains(CONFIG, stdbinary) { QMAKE_LIBS += - } else { + } else:contains(CONFIG,qt) { QMAKE_LIBS += $$QMAKE_LIBS_QT_ENTRY + } else { + QMAKE_LIBS += $$QMAKE_LIBS_NO_QT_ENTRY } default_bin_deployment.files += $$symbianRemoveSpecialCharacters($$basename(TARGET)).exe diff --git a/mkspecs/features/symbian/symbian_building.prf b/mkspecs/features/symbian/symbian_building.prf index 8236884..9288583 100644 --- a/mkspecs/features/symbian/symbian_building.prf +++ b/mkspecs/features/symbian/symbian_building.prf @@ -198,16 +198,29 @@ contains(TEMPLATE, app):!contains(QMAKE_LINK, "^@:.*") { symbian-armcc: { QMAKE_LIBS += usrt2_2.lib dfpaeabi.dso dfprvct2_2.dso drtaeabi.dso scppnwdl.dso drtrvct2_2.dso h_t__uf.l\\(switch8.o\\) QMAKE_LIBS += -leexe.lib\\(uc_exe_.o\\) - QMAKE_LIBS -= $$QMAKE_LIBS_QT_ENTRY - QMAKE_LIBS += $$QMAKE_LIBS_QT_ENTRY + contains(CONFIG, "qt") { + QMAKE_LIBS -= $$QMAKE_LIBS_QT_ENTRY + QMAKE_LIBS += $$QMAKE_LIBS_QT_ENTRY + } else { + QMAKE_LIBS -= $$QMAKE_LIBS_NO_QT_ENTRY + QMAKE_LIBS += $$QMAKE_LIBS_NO_QT_ENTRY + } } else :symbian-gcce { # notice that we can't merge these as ordering of arguments is important. QMAKE_LIBS += \ -l:eexe.lib \ -l:usrt2_2.lib - modified_entry = $$replace(QMAKE_LIBS_QT_ENTRY, "^-l", "-l:") - QMAKE_LIBS -= $$modified_entry - QMAKE_LIBS += $$modified_entry + contains(CONFIG, "qt") { + modified_entry = $$replace(QMAKE_LIBS_QT_ENTRY, "^-l", "-l:") + QMAKE_LIBS -= $$modified_entry + QMAKE_LIBS += $$modified_entry + } else { + modified_entry = $$replace(QMAKE_LIBS_NO_QT_ENTRY, "^-l", "-l:") + QMAKE_LIBS -= $$modified_entry + modified_entry = $$replace(QMAKE_LIBS_NO_QT_ENTRY_GCCE, "^-l", "-l:") + QMAKE_LIBS -= $$modified_entry + QMAKE_LIBS += $$modified_entry + } QMAKE_LIBS += \ -l:dfpaeabi.dso \ -l:drtaeabi.dso \ -- cgit v0.12 From 793d1ac6dc6faf1485317d4c8a7f9026468374b3 Mon Sep 17 00:00:00 2001 From: axis Date: Mon, 8 Nov 2010 16:13:54 +0100 Subject: Fixed deployment for symbian/linux-armcc when using shadow builds. RevBy: Miikka Heikkinen --- mkspecs/features/symbian/application_icon.prf | 8 +++++--- mkspecs/features/symbian/default_post.prf | 10 ++++++++-- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/mkspecs/features/symbian/application_icon.prf b/mkspecs/features/symbian/application_icon.prf index f43ec3d..0fe6305 100644 --- a/mkspecs/features/symbian/application_icon.prf +++ b/mkspecs/features/symbian/application_icon.prf @@ -15,10 +15,12 @@ contains(CONFIG, no_icon) { resourceZDir = $$EPOCROOT$$HW_ZDIR$$APP_RESOURCE_DIR regZDir = $$EPOCROOT$$HW_ZDIR$$REG_RESOURCE_IMPORT_DIR } else { - isEmpty(DESTDIR) { - resourceZDir = . - } else { + contains(DESTDIR, "/.*") { resourceZDir = $$DESTDIR + } else:isEmpty(DESTDIR) { + resourceZDir = $$OUT_PWD + } else { + resourceZDir = $$OUT_PWD/$$DESTDIR } regZDir = $$resourceZDir } diff --git a/mkspecs/features/symbian/default_post.prf b/mkspecs/features/symbian/default_post.prf index fe1f6d3..22e3c82 100644 --- a/mkspecs/features/symbian/default_post.prf +++ b/mkspecs/features/symbian/default_post.prf @@ -8,8 +8,14 @@ contains(TEMPLATE, ".*app") { } else { QMAKE_LIBS += $$QMAKE_LIBS_NO_QT_ENTRY } - - default_bin_deployment.files += $$symbianRemoveSpecialCharacters($$basename(TARGET)).exe + + contains(DESTDIR, "/.*") { + default_bin_deployment.sources += $$DESTDIR/$$symbianRemoveSpecialCharacters($$basename(TARGET)).exe + } else:isEmpty(DESTDIR) { + default_bin_deployment.sources += $$OUT_PWD/$$symbianRemoveSpecialCharacters($$basename(TARGET)).exe + } else { + default_bin_deployment.sources += $$OUT_PWD/$$DESTDIR/$$symbianRemoveSpecialCharacters($$basename(TARGET)).exe + } default_bin_deployment.path += /sys/bin load(application_icon.prf) -- cgit v0.12 From d25330abf4bfe73b7c2867923c461a762747c485 Mon Sep 17 00:00:00 2001 From: aavit Date: Tue, 9 Nov 2010 12:20:26 +0100 Subject: Really fix getting qmakespec on windows --- tests/arthur/common/baselineprotocol.cpp | 3 +-- tests/auto/lancelot/lancelot.pro | 4 +++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/arthur/common/baselineprotocol.cpp b/tests/arthur/common/baselineprotocol.cpp index 3fdef88..2a41104 100644 --- a/tests/arthur/common/baselineprotocol.cpp +++ b/tests/arthur/common/baselineprotocol.cpp @@ -58,8 +58,7 @@ PlatformInfo::PlatformInfo(bool useLocal) if (useLocal) { insert(PI_HostName, QHostInfo::localHostName()); insert(PI_QtVersion, QLS(qVersion())); - QString mkspec = QDir::fromNativeSeparators(QLS(QMAKESPEC)).remove(QRegExp(QLS("^.*/mkspecs/"))); - insert(PI_QMakeSpec, mkspec); + insert(PI_QMakeSpec, QString(QLS(QMAKESPEC)).remove(QRegExp(QLS("^.*mkspecs/")))); insert(PI_BuildKey, QLibraryInfo::buildKey()); #if defined(Q_OS_LINUX) insert(PI_OSName, QLS("Linux")); diff --git a/tests/auto/lancelot/lancelot.pro b/tests/auto/lancelot/lancelot.pro index 6498f6c..4535b83 100644 --- a/tests/auto/lancelot/lancelot.pro +++ b/tests/auto/lancelot/lancelot.pro @@ -8,6 +8,8 @@ HEADERS += $$QT_SOURCE_TREE/tests/arthur/common/paintcommands.h RESOURCES += $$QT_SOURCE_TREE/tests/arthur/common/images.qrc include($$QT_SOURCE_TREE/tests/arthur/common/baselineprotocol.pri) -DEFINES += QMAKESPEC=\\\"$$QMAKESPEC\\\" +win32|symbian*:MKSPEC=$$replace(QMAKESPEC, \\\\, /) +else:MKSPEC=$$QMAKESPEC +DEFINES += QMAKESPEC=\\\"$$MKSPEC\\\" !symbian:!wince*:DEFINES += SRCDIR=\\\"$$PWD\\\" -- cgit v0.12