summaryrefslogtreecommitdiffstats
path: root/tools/checksdk
diff options
context:
space:
mode:
authormread <qt-info@nokia.com>2009-08-07 13:34:12 (GMT)
committermread <qt-info@nokia.com>2009-08-07 13:34:12 (GMT)
commit5a72890b7ce12815f9567316da867006cff73f39 (patch)
tree46c8c793f19274f9ed19678d1732d2123adbdf34 /tools/checksdk
parent0f6f1f841cea61cbb6905de92c2ca63bd369d55d (diff)
parentcc0a411e5e874aa224c26298a109973cb15ea291 (diff)
downloadQt-5a72890b7ce12815f9567316da867006cff73f39.zip
Qt-5a72890b7ce12815f9567316da867006cff73f39.tar.gz
Qt-5a72890b7ce12815f9567316da867006cff73f39.tar.bz2
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt-s60-public
Conflicts fixed: src/corelib/io/qdiriterator.cpp
Diffstat (limited to 'tools/checksdk')
-rw-r--r--tools/checksdk/cesdkhandler.cpp7
-rw-r--r--tools/checksdk/cesdkhandler.h4
-rw-r--r--tools/checksdk/checksdk.pro39
-rw-r--r--tools/checksdk/main.cpp42
4 files changed, 32 insertions, 60 deletions
diff --git a/tools/checksdk/cesdkhandler.cpp b/tools/checksdk/cesdkhandler.cpp
index 48452a3..677d003 100644
--- a/tools/checksdk/cesdkhandler.cpp
+++ b/tools/checksdk/cesdkhandler.cpp
@@ -71,15 +71,15 @@ bool CeSdkHandler::parse()
// look at the file at %VCInstallDir%/vcpackages/WCE.VCPlatform.config
// and scan through all installed sdks...
m_list.clear();
- VCInstallDir = qgetenv("VCInstallDir");
+ VCInstallDir = QString::fromLatin1(qgetenv("VCInstallDir"));
VCInstallDir += QLatin1String("\\");
- VSInstallDir = qgetenv("VSInstallDir");
+ VSInstallDir = QString::fromLatin1(qgetenv("VSInstallDir"));
VSInstallDir += QLatin1String("\\");
if (VCInstallDir.isEmpty() || VSInstallDir.isEmpty())
return false;
QDir vStudioDir(VCInstallDir);
- if (!vStudioDir.cd("vcpackages"))
+ if (!vStudioDir.cd(QLatin1String("vcpackages")))
return false;
QFile configFile(vStudioDir.absoluteFilePath(QLatin1String("WCE.VCPlatform.config")));
@@ -118,6 +118,7 @@ bool CeSdkHandler::parse()
qWarning() << "XML ERROR:" << xml.lineNumber() << ": " << xml.errorString();
return false;
}
+
return m_list.size() > 0 ? true : false;
}
diff --git a/tools/checksdk/cesdkhandler.h b/tools/checksdk/cesdkhandler.h
index 04d3bdf..6ec26db 100644
--- a/tools/checksdk/cesdkhandler.h
+++ b/tools/checksdk/cesdkhandler.h
@@ -102,8 +102,8 @@ inline QList<CeSdkInfo> CeSdkHandler::listAll() const
inline QString CeSdkHandler::fixPaths(QString path) const
{
- QString str = QDir::toNativeSeparators(QDir::cleanPath(path.replace(VCINSTALL_MACRO, VCInstallDir).replace(VSINSTALL_MACRO, VSInstallDir).replace(QLatin1String("$(PATH)"), QLatin1String("%PATH%"))));
- if (str.endsWith(';'))
+ QString str = QDir::toNativeSeparators(QDir::cleanPath(path.replace(QLatin1String(VCINSTALL_MACRO), VCInstallDir).replace(QLatin1String(VSINSTALL_MACRO), VSInstallDir).replace(QLatin1String("$(PATH)"), QLatin1String("%PATH%"))));
+ if (str.endsWith(QLatin1Char(';')))
str.truncate(str.length() - 1);
return str;
}
diff --git a/tools/checksdk/checksdk.pro b/tools/checksdk/checksdk.pro
index e364f26..a513981 100644
--- a/tools/checksdk/checksdk.pro
+++ b/tools/checksdk/checksdk.pro
@@ -32,40 +32,5 @@ SOURCES += \
HEADERS += \
cesdkhandler.h
-# Bootstrapped Input
-SOURCES += \
- $$QT_SOURCE_TREE/src/corelib/kernel/qmetatype.cpp \
- $$QT_SOURCE_TREE/src/corelib/kernel/qvariant.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qstring.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qstringlist.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfile.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qdir.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qabstractfileengine.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_win.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_iterator.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_iterator_win.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qfileinfo.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qtemporaryfile.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qdiriterator.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qiodevice.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qbuffer.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qtextstream.cpp \
- $$QT_SOURCE_TREE/src/corelib/io/qurl.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qdatetime.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qlocale.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qbytearray.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qbytearraymatcher.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qvector.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qvsnprintf.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qlistdata.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qhash.cpp \
- $$QT_SOURCE_TREE/src/corelib/global/qglobal.cpp \
- $$QT_SOURCE_TREE/src/corelib/global/qmalloc.cpp \
- $$QT_SOURCE_TREE/src/corelib/global/qnumeric.cpp \
- $$QT_SOURCE_TREE/src/corelib/xml/qxmlstream.cpp \
- $$QT_SOURCE_TREE/src/corelib/xml/qxmlutils.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qregexp.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qmap.cpp \
- $$QT_SOURCE_TREE/src/corelib/tools/qbitarray.cpp \
- $$QT_BUILD_TREE/src/corelib/global/qconfig.cpp
+include(../../src/tools/bootstrap/bootstrap.pri)
+
diff --git a/tools/checksdk/main.cpp b/tools/checksdk/main.cpp
index 2dd7214..6322eb7 100644
--- a/tools/checksdk/main.cpp
+++ b/tools/checksdk/main.cpp
@@ -46,17 +46,17 @@
void usage()
{
- qDebug() << "SDK Scanner - Convenience Tool to setup your environment";
- qDebug() << " for crosscompilation to Windows CE";
- qDebug() << "Options:";
- qDebug() << "-help This output";
- qDebug() << "-list List all available SDKs";
- qDebug() << "-sdk <name> Select specified SDK.";
- qDebug() << " Note: SDK names with spaces need to be";
- qDebug() << " specified in parenthesis";
- qDebug() << " default: Windows Mobile 5.0 Pocket PC SDK (ARMV4I)";
- qDebug() << "-script <file> Create a script file which can be launched";
- qDebug() << " to setup your environment for specified SDK";
+ printf("SDK Scanner - Convenience Tool to setup your environment\n");
+ printf(" for crosscompilation to Windows CE\n");
+ printf("Options:\n");
+ printf("-help This output\n");
+ printf("-list List all available SDKs\n");
+ printf("-sdk <name> Select specified SDK.\n");
+ printf(" Note: SDK names with spaces need to be\n");
+ printf(" specified in parenthesis\n");
+ printf(" default: Windows Mobile 5.0 Pocket PC SDK (ARMV4I)\n");
+ printf("-script <file> Create a script file which can be launched\n");
+ printf(" to setup your environment for specified SDK\n");
}
int main(int argc, char **argv)
@@ -106,9 +106,12 @@ int main(int argc, char **argv)
QList<CeSdkInfo> list = handler.listAll();
if (operationList) {
- qDebug() << "Available SDKs:";
- for (QList<CeSdkInfo>::iterator it = list.begin(); it != list.end(); ++it)
- qDebug() << "SDK Name:" << it->name();
+ printf("Available SDKs:\n");
+ for (QList<CeSdkInfo>::iterator it = list.begin(); it != list.end(); ++it) {
+ printf("SDK Name: ");
+ printf(qPrintable(it->name()));
+ printf("\n");
+ }
return 0;
}
@@ -132,10 +135,13 @@ int main(int argc, char **argv)
includePath = QString::fromLatin1("INCLUDE=") + it->includePath();
libPath = QString::fromLatin1("LIB=") + it->libPath();
if (scriptFile.isEmpty()) {
- qDebug() << "Please set up your environment with the following paths:";
- qDebug() << qPrintable(binPath);
- qDebug() << qPrintable(includePath);
- qDebug() << qPrintable(libPath);
+ printf("Please set up your environment with the following paths:\n");
+ printf(qPrintable(binPath));
+ printf("\n");
+ printf(qPrintable(includePath));
+ printf("\n");
+ printf(qPrintable(libPath));
+ printf("\n");
return 0;
} else {
QFile file(scriptFile);