summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkku Luukkainen <markku.luukkainen@digia.com>2009-04-28 06:58:52 (GMT)
committerMarkku Luukkainen <markku.luukkainen@digia.com>2009-04-28 06:58:52 (GMT)
commit1cfc9445d1fcfce2e803f14afef1b6ee3f3d0121 (patch)
treeb942ee0146dc6176191511a0981c28d07ef2575a
parent9a17e2ac3f9654f7f328aeae5673cff1254517ae (diff)
parent80d776da9ee985236b3f5bea74e8d2d61cc00a88 (diff)
downloadQt-1cfc9445d1fcfce2e803f14afef1b6ee3f3d0121.zip
Qt-1cfc9445d1fcfce2e803f14afef1b6ee3f3d0121.tar.gz
Qt-1cfc9445d1fcfce2e803f14afef1b6ee3f3d0121.tar.bz2
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt-s60-public
-rw-r--r--mkspecs/common/symbian/symbian.conf2
-rw-r--r--mkspecs/symbian-sbsv2/flm/qt/qmake_emulator_deployment.flm21
-rw-r--r--mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm2
-rw-r--r--qmake/generators/symbian/symmake_abld.cpp2
-rw-r--r--qmake/generators/symbian/symmake_sbsv2.cpp4
-rw-r--r--src/corelib/corelib.pro8
-rw-r--r--src/s60installs/qt_libs.pro6
-rw-r--r--src/sql/sql.pro8
-rw-r--r--tests/auto/network-settings.h140
-rw-r--r--tests/auto/qsslsocket/tst_qsslsocket.cpp7
10 files changed, 167 insertions, 33 deletions
diff --git a/mkspecs/common/symbian/symbian.conf b/mkspecs/common/symbian/symbian.conf
index f39a5d6..81b439a 100644
--- a/mkspecs/common/symbian/symbian.conf
+++ b/mkspecs/common/symbian/symbian.conf
@@ -107,7 +107,7 @@ QMAKE_STRIPFLAGS_LIB += --strip-unneeded
load(qt_config)
load(platform_paths)
-MMP_RULES += EXPORTUNFROZEN
+MMP_RULES += EXPORTUNFROZEN PAGED
SYMBIAN_PLATFORMS = WINSCW GCCE ARMV5
# Legacy support requires some hardcoded stdapis paths.
diff --git a/mkspecs/symbian-sbsv2/flm/qt/qmake_emulator_deployment.flm b/mkspecs/symbian-sbsv2/flm/qt/qmake_emulator_deployment.flm
index 8c5ad9e..354ce26 100644
--- a/mkspecs/symbian-sbsv2/flm/qt/qmake_emulator_deployment.flm
+++ b/mkspecs/symbian-sbsv2/flm/qt/qmake_emulator_deployment.flm
@@ -10,25 +10,30 @@
include $(FLMHOME)/metaflm.mk
SINGLETON:=$(call sanitise,TARGET_$(DEPLOY_TARGET))
+CLEAN_TARGET:=
define qmake_emulator_deployment
-$(ALLTARGET):: $(DEPLOY_TARGET)
-FINAL:: $(DEPLOY_TARGET)
+$(ALLTARGET):: $(1)
+FINAL::$(1)
# Prevent duplicate targets from being created
$(SINGLETON):=1
-$(DEPLOY_TARGET): $(DEPLOY_SOURCE)
+CLEAN_TARGET:=$(1)
+
+$(1): $(2)
$(call startrule,qmake_emulator_deployment) \
- $(GNUCP) -u -T $(DEPLOY_SOURCE) $(DEPLOY_TARGET) \
- $(call endrule,qmake_emulator_deployment)
+ $(GNUCP) --no-preserve=mode $(2) "$$@" && \
+ $(GNUCHMOD) a+rw "$$@" \
+ $(call endrule,qmake_emulator_deployment)
endef
ifeq ($($(SINGLETON)),)
-$(eval $(qmake_emulator_deployment))
+$(eval $(call qmake_emulator_deployment, $(subst $(CHAR_SPACE),\$(CHAR_SPACE),$(DEPLOY_TARGET)), $(subst $(CHAR_SPACE),\$(CHAR_SPACE),$(DEPLOY_SOURCE))))
+$(call makepath,$(dir $(DEPLOY_TARGET)))
+$(eval $(call GenerateStandardCleanTarget,$(CLEAN_TARGET),''))
endif
-$(call makepathfor,$(DEPLOY_TARGET))
-$(eval $(call GenerateStandardCleanTarget,$(DEPLOY_TARGET),''))
+
diff --git a/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm b/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
index b6f5961..9dc529f 100644
--- a/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
+++ b/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
@@ -28,8 +28,8 @@ endef
ifeq ($($(SINGLETON)),)
$(eval $(qmake_extra_pre_targetdep))
+$(eval $(call GenerateStandardCleanTarget,$(PREDEP_TARGET),''))
endif
-$(eval $(call GenerateStandardCleanTarget,$(PREDEP_TARGET),''))
diff --git a/qmake/generators/symbian/symmake_abld.cpp b/qmake/generators/symbian/symmake_abld.cpp
index d1942c6..aee9745 100644
--- a/qmake/generators/symbian/symmake_abld.cpp
+++ b/qmake/generators/symbian/symmake_abld.cpp
@@ -157,7 +157,7 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
t << "QMAKE = " << Option::fixPathToTargetOS(var("QMAKE_QMAKE")) << endl;
t << "DEL_FILE = " << var("QMAKE_DEL_FILE") << endl;
t << "DEL_DIR = " << var("QMAKE_DEL_DIR") << endl;
- t << "XCOPY = xcopy /d /f /h /r /k /y /i" << endl;
+ t << "XCOPY = xcopy /d /f /h /r /y /i" << endl;
t << "ABLD = ABLD.BAT" << endl;
t << "DEBUG_PLATFORMS = " << debugPlatforms.join(" ") << endl;
t << "RELEASE_PLATFORMS = " << releasePlatforms.join(" ") << endl;
diff --git a/qmake/generators/symbian/symmake_sbsv2.cpp b/qmake/generators/symbian/symmake_sbsv2.cpp
index 2a15ee5..541226f 100644
--- a/qmake/generators/symbian/symmake_sbsv2.cpp
+++ b/qmake/generators/symbian/symmake_sbsv2.cpp
@@ -350,16 +350,18 @@ bool SymbianSbsv2MakefileGenerator::writeBldInfExtensionRulesPart(QTextStream& t
DeploymentList depList;
initProjectDeploySymbian( project, depList, remoteTestPath, false, QLatin1String("winscw"), QLatin1String("udeb"), generatedDirs, generatedFiles );
+ t << "#if defined(WINSCW)" << endl;
for (int i=0; i<depList.size(); ++i) {
t << "START EXTENSION qt/qmake_emulator_deployment" << endl;
QString fromItem = depList.at(i).from;
QString toItem = depList.at(i).to;
fromItem.replace("\\", "/");
- toItem.replace("\\", "/");
+ toItem.replace("\\", "/").prepend(QDir::current().absolutePath().left(2)); // add drive
t << "OPTION DEPLOY_SOURCE " << fromItem << endl;
t << "OPTION DEPLOY_TARGET " << toItem << endl;
t << "END" << endl;
}
+ t << "#endif" << endl;
t << endl;
#endif
diff --git a/src/corelib/corelib.pro b/src/corelib/corelib.pro
index 469225e..c55c2da 100644
--- a/src/corelib/corelib.pro
+++ b/src/corelib/corelib.pro
@@ -27,4 +27,10 @@ QMAKE_DYNAMIC_LIST_FILE = $$PWD/QtCore.dynlist
contains(DEFINES,QT_EVAL):include(eval.pri)
-symbian:TARGET.UID3=0x2001B2DC \ No newline at end of file
+symbian: {
+ TARGET.UID3=0x2001B2DC
+
+ # Workaroud for problems with paging this dll
+ MMP_RULES -= PAGED
+ MMP_RULES *= UNPAGED
+} \ No newline at end of file
diff --git a/src/s60installs/qt_libs.pro b/src/s60installs/qt_libs.pro
index 546c5b6..2ba8b79 100644
--- a/src/s60installs/qt_libs.pro
+++ b/src/s60installs/qt_libs.pro
@@ -42,11 +42,9 @@ symbian: {
#ENDIF
qtlibraries.path = /sys/bin
- qtlibraries.depends = "(0x20009a80), 1, 5, 0, {\"Symbian OS PIPS\"}"
+ qtlibraries.depends = "(0x20013851), 1, 5, 1, {\"PIPS Installer\"}"
contains(QT_CONFIG, openssl) | contains(QT_CONFIG, openssl-linked) {
- qtlibraries.depends += "(0x200110CB), 1, 5, 0, {\"Open C LIBSSL Common\"}"
- qtlibraries.depends += "(0x10281f34), 1, 5, 0, {\"Open C LIBSSL\"}"
- qtlibraries.depends += "(0x2001B28B), 1, 5, 0, {\"OpenC LIBZ Support Files\"}"
+ qtlibraries.depends += "(0x200110CB), 1, 5, 1, {\"Open C LIBSSL Common\"}"
}
contains(QT_CONFIG, stl) {
qtlibraries.depends += "(0x2000F866), 1, 0, 0, {\"Standard C++ Library Common\"}"
diff --git a/src/sql/sql.pro b/src/sql/sql.pro
index f089dd7..60be748 100644
--- a/src/sql/sql.pro
+++ b/src/sql/sql.pro
@@ -17,5 +17,11 @@ include(kernel/kernel.pri)
include(drivers/drivers.pri)
include(models/models.pri)
-symbian:TARGET.UID3=0x2001E61D
+symbian: {
+ TARGET.UID3=0x2001E61D
+
+ # Workaroud for problems with paging this dll
+ MMP_RULES -= PAGED
+ MMP_RULES *= UNPAGED
+}
diff --git a/tests/auto/network-settings.h b/tests/auto/network-settings.h
index 663d817..4cee7ed 100644
--- a/tests/auto/network-settings.h
+++ b/tests/auto/network-settings.h
@@ -43,6 +43,8 @@
#ifdef Q_OS_SYMBIAN
#include <sys/socket.h>
#include <net/if.h>
+#include <QSharedPointer>
+#include <QHash>
#endif
#if defined(Q_OS_SYMBIAN) && defined(Q_CC_NOKIAX86)
// In emulator we use WINSOCK connectivity by default. Unfortunately winsock
@@ -55,22 +57,62 @@
//#define SYMBIAN_WINSOCK_CONNECTIVITY
#endif
+ class QtNetworkSettingsRecord {
+ public:
+ QtNetworkSettingsRecord() { }
+
+ QtNetworkSettingsRecord(const QString& recName, const QString& recVal)
+ : strRecordName(recName), strRecordValue(recVal) { }
+
+ QtNetworkSettingsRecord(const QtNetworkSettingsRecord & other)
+ : strRecordName(other.strRecordName), strRecordValue(other.strRecordValue) { }
+
+ ~QtNetworkSettingsRecord() { }
+
+ const QString& recordName() const { return strRecordName; }
+ const QString& recordValue() const { return strRecordValue; }
+
+ private:
+ QString strRecordName;
+ QString strRecordValue;
+ };
+
class QtNetworkSettings
{
public:
+
static QString serverLocalName()
{
+#ifdef Q_OS_SYMBIAN
+ loadTestSettings();
+
+ if(QtNetworkSettings::entries.contains("server.localname")) {
+ QtNetworkSettingsRecord* entry = entries["server.localname"];
+ return entry->recordValue();
+ }
+#endif
return QString("qttest");
//return QString("aspiriniks");
//return QString("qt-test-server");
}
static QString serverDomainName()
{
+#ifdef Q_OS_SYMBIAN
+ loadTestSettings();
+
+ if(QtNetworkSettings::entries.contains("server.domainname")) {
+ QtNetworkSettingsRecord* entry = entries["server.domainname"];
+ return entry->recordValue();
+ }
+#endif
return QString("it.local");
//return QString("troll.no");
}
static QString serverName()
{
+#ifdef Q_OS_SYMBIAN
+ loadTestSettings();
+#endif
return serverLocalName() + "." + serverDomainName();
}
static QString winServerName()
@@ -84,6 +126,18 @@ public:
}
static const char *serverIP()
{
+#ifdef Q_OS_SYMBIAN
+ loadTestSettings();
+
+ if(QtNetworkSettings::entries.contains("server.ip")) {
+ QtNetworkSettingsRecord* entry = entries["server.ip"];
+ QByteArray valueAsAscii = entry->recordValue().toAscii();
+ if(*serverIPAscii == 0) {
+ ::strcpy(serverIPAscii, valueAsAscii.data());
+ }
+ return serverIPAscii;
+ }
+#endif
//return "10.10.0.147";
return "10.10.14.172";
//return "10.3.7.2";
@@ -114,6 +168,7 @@ public:
expected = expected.append(" Cyrus IMAP4 v2.3.11-Mandriva-RPM-2.3.11-6mdv2008.1 server ready\r\n");
return expected;
}
+<<<<<<< HEAD:tests/auto/network-settings.h
static QByteArray expectedReplyFtp()
{
@@ -122,6 +177,8 @@ public:
expected = expected.append(" Cyrus IMAP4 v2.3.11-Mandriva-RPM-2.3.11-6mdv2008.1 server ready\r\n");
return expected;
}
+=======
+>>>>>>> 6d41f31... Nwteork server test related data (serever name, IP address ...) can now:tests/auto/network-settings.h
#ifdef Q_OS_SYMBIAN
static void setDefaultIap()
@@ -139,50 +196,107 @@ public:
private:
#ifdef Q_OS_SYMBIAN
- static bool bIsIapLoaded;
+
+ static QHash<QString, QtNetworkSettingsRecord* > entries;
+ static bool bDefaultIapLoaded;
+ static bool bTestSettingsLoaded;
static QString iapFileFullPath;
- static QString defaultIap;
+ static QString strDefaultIap;
+ static char serverIPAscii[256];
static QString getDefaultIap() {
- if(!bIsIapLoaded)
- loadIapCfg();
+ if(!bDefaultIapLoaded) {
+ if(!loadDefaultIap()) // not found in file - use default
+ strDefaultIap = QString("Lab");
+ }
- return defaultIap;
+ return strDefaultIap;
}
- static void loadIapCfg() {
+ static bool loadDefaultIap() {
QFile iapCfgFile(iapFileFullPath);
+ bool bFoundDefaultIapTag = false;
+
if (iapCfgFile.open(QFile::ReadOnly)) {
QTextStream input(&iapCfgFile);
QString line;
- bool bFoundDefaultTag = false;
do {
line = input.readLine().trimmed();
if(line.startsWith(QString("#")))
continue; // comment found
if(line.contains(QString("[DEFAULT]"))) {
- bFoundDefaultTag = true;
- } else if(line.startsWith(QString("[")) && bFoundDefaultTag) {
+ bFoundDefaultIapTag = true;
+ } else if(line.startsWith(QString("[")) && bFoundDefaultIapTag) {
+ bFoundDefaultIapTag = false;
break; // stick to default
}
- if(bFoundDefaultTag && line.contains("name")) {
+ if(bFoundDefaultIapTag && line.contains("name")) {
int position = line.indexOf(QString("="));
position += QString("=").length();
- defaultIap = line.mid(position).trimmed();
+ strDefaultIap = line.mid(position).trimmed();
break;
}
} while (!line.isNull());
}
+
+ return bFoundDefaultIapTag;
+ }
+
+ static bool loadTestSettings() {
+ if(bTestSettingsLoaded)
+ return true;
+
+ QFile cfgFile(iapFileFullPath);
+ bool bFoundTestTag = false;
+
+ if (cfgFile.open(QFile::ReadOnly)) {
+ QTextStream input(&cfgFile);
+ QString line;
+ do {
+ line = input.readLine().trimmed();
+
+ if(line.startsWith(QString("#")) || line.length() == 0)
+ continue; // comment or empty line found
+
+ if(line.contains(QString("[TEST]"))) {
+ bFoundTestTag = true;
+ } else if(line.startsWith(QString("[")) && bFoundTestTag) {
+ bFoundTestTag = false;
+ break; // finished with test tag
+ }
+
+ if(bFoundTestTag) { // non-empty line
+ int position = line.indexOf(QString("="));
+
+ if(position <= 0) // not found
+ continue;
+
+ // found - extract
+
+ QString recname = line.mid(0, position - QString("=").length()).trimmed();
+ QString recval = line.mid(position + QString("=").length()).trimmed();
+
+ //create record
+ QtNetworkSettingsRecord *entry = new QtNetworkSettingsRecord(recname, recval);
+ entries.insert(entry->recordName(), entry);
+ }
+ } while (!line.isNull());
+ }
+
+ return bTestSettingsLoaded = true;
}
#endif
};
#ifdef Q_OS_SYMBIAN
-bool QtNetworkSettings::bIsIapLoaded = false;
+QHash<QString, QtNetworkSettingsRecord* > QtNetworkSettings::entries = QHash<QString, QtNetworkSettingsRecord* > ();
+bool QtNetworkSettings::bDefaultIapLoaded = false;
+bool QtNetworkSettings::bTestSettingsLoaded = false;
QString QtNetworkSettings::iapFileFullPath = QString("C:\\Data\\iap.txt");
-QString QtNetworkSettings::defaultIap = QString("Lab"); // this will be default value
+QString QtNetworkSettings::strDefaultIap = QString("");
+char QtNetworkSettings::serverIPAscii[256];
#endif
#ifdef Q_OS_SYMBIAN
diff --git a/tests/auto/qsslsocket/tst_qsslsocket.cpp b/tests/auto/qsslsocket/tst_qsslsocket.cpp
index 67c7485..b62d629 100644
--- a/tests/auto/qsslsocket/tst_qsslsocket.cpp
+++ b/tests/auto/qsslsocket/tst_qsslsocket.cpp
@@ -1283,7 +1283,11 @@ protected:
// delayed acceptance:
QTest::qSleep(100);
- server.waitForNewConnection(2000);
+#ifndef Q_OS_SYMBIAN
+ bool ret = server.waitForNewConnection(2000);
+#else
+ bool ret = server.waitForNewConnection(20000);
+#endif
// delayed start of encryption
QTest::qSleep(100);
@@ -1329,7 +1333,6 @@ protected:
void tst_QSslSocket::waitForMinusOne()
{
-QSKIP("App stucks here if synchornized socket operations in use", SkipAll);
QFETCH_GLOBAL(bool, setProxy);
if (setProxy)
return;