summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2010-03-24 18:13:39 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2010-03-24 18:13:39 (GMT)
commit3039c483cd2c402457e7f9cbc672ec9254d09c57 (patch)
tree117077c4c4ab669d1db57ae89f7afbbb76a27bdb /tools
parent5ddcc726a623fea3534f76c07b6c1d2835a0e2d6 (diff)
parente15d5fc7e1a82da38b765e55d040edbdf8621ae2 (diff)
downloadQt-3039c483cd2c402457e7f9cbc672ec9254d09c57.zip
Qt-3039c483cd2c402457e7f9cbc672ec9254d09c57.tar.gz
Qt-3039c483cd2c402457e7f9cbc672ec9254d09c57.tar.bz2
Merge remote branch 'origin/4.7' into HEAD
Conflicts: src/declarative/qml/qdeclarativecompiler.cpp
Diffstat (limited to 'tools')
-rw-r--r--tools/configure/configureapp.cpp27
-rw-r--r--tools/configure/environment.cpp4
-rw-r--r--tools/shared/windows/registry.cpp2
3 files changed, 19 insertions, 14 deletions
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp
index 0aca545..0b14cba 100644
--- a/tools/configure/configureapp.cpp
+++ b/tools/configure/configureapp.cpp
@@ -1886,7 +1886,7 @@ bool Configure::findFile( const QString &fileName )
const QString file = fileName.toLower();
const QString pathEnvVar = QString::fromLocal8Bit(getenv("PATH"));
const QString mingwPath = dictionary["QMAKESPEC"].endsWith("-g++") ?
- findFileInPaths("mingw32-g++.exe", pathEnvVar) : QString();
+ findFileInPaths("g++.exe", pathEnvVar) : QString();
QString paths;
if (file.endsWith(".h")) {
@@ -1978,7 +1978,7 @@ bool Configure::checkAvailability(const QString &part)
{
bool available = false;
if (part == "STYLE_WINDOWSXP")
- available = (findFile("uxtheme.h"));
+ available = findFile("uxtheme.h");
else if (part == "ZLIB")
available = findFile("zlib.h");
@@ -3508,14 +3508,15 @@ void Configure::buildQmake()
args += makefile;
cout << "Creating qmake..." << endl;
- int exitCode = 0;
- if( exitCode = Environment::execute(args, QStringList(), QStringList()) ) {
+ int exitCode = Environment::execute(args, QStringList(), QStringList());
+ if( exitCode ) {
args.clear();
args += dictionary[ "MAKE" ];
args += "-f";
args += makefile;
args += "clean";
- if( exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ exitCode = Environment::execute(args, QStringList(), QStringList());
+ if(exitCode) {
cout << "Cleaning qmake failed, return code " << exitCode << endl << endl;
dictionary[ "DONE" ] = "error";
} else {
@@ -3523,7 +3524,8 @@ void Configure::buildQmake()
args += dictionary[ "MAKE" ];
args += "-f";
args += makefile;
- if (exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ exitCode = Environment::execute(args, QStringList(), QStringList());
+ if (exitCode) {
cout << "Building qmake failed, return code " << exitCode << endl << endl;
dictionary[ "DONE" ] = "error";
}
@@ -3567,8 +3569,8 @@ void Configure::buildHostTools()
QDir().mkpath(toolBuildPath);
QDir::setCurrent(toolSourcePath);
- int exitCode = 0;
- if (exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ int exitCode = Environment::execute(args, QStringList(), QStringList());
+ if (exitCode) {
cout << "qmake failed, return code " << exitCode << endl << endl;
dictionary["DONE"] = "error";
break;
@@ -3578,18 +3580,21 @@ void Configure::buildHostTools()
args.clear();
args += dictionary["MAKE"];
QDir::setCurrent(toolBuildPath);
- if (exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ exitCode = Environment::execute(args, QStringList(), QStringList());
+ if (exitCode) {
args.clear();
args += dictionary["MAKE"];
args += "clean";
- if(exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ exitCode = Environment::execute(args, QStringList(), QStringList());
+ if(exitCode) {
cout << "Cleaning " << hostToolsDirs.at(i) << " failed, return code " << exitCode << endl << endl;
dictionary["DONE"] = "error";
break;
} else {
args.clear();
args += dictionary["MAKE"];
- if (exitCode = Environment::execute(args, QStringList(), QStringList())) {
+ exitCode = Environment::execute(args, QStringList(), QStringList());
+ if (exitCode) {
cout << "Building " << hostToolsDirs.at(i) << " failed, return code " << exitCode << endl << endl;
dictionary["DONE"] = "error";
break;
diff --git a/tools/configure/environment.cpp b/tools/configure/environment.cpp
index e93f9a0..74bebb2 100644
--- a/tools/configure/environment.cpp
+++ b/tools/configure/environment.cpp
@@ -357,7 +357,7 @@ int Environment::execute(QStringList arguments, const QStringList &additionalEnv
QString args = qt_create_commandline(program, arguments);
QByteArray envlist = qt_create_environment(fullEnv);
- DWORD exitCode = -1;
+ DWORD exitCode = DWORD(-1);
PROCESS_INFORMATION procInfo;
memset(&procInfo, 0, sizeof(procInfo));
@@ -378,7 +378,7 @@ int Environment::execute(QStringList arguments, const QStringList &additionalEnv
}
- if (exitCode == -1) {
+ if (exitCode == DWORD(-1)) {
switch(GetLastError()) {
case E2BIG:
cerr << "execute: Argument list exceeds 1024 bytes" << endl;
diff --git a/tools/shared/windows/registry.cpp b/tools/shared/windows/registry.cpp
index d342d78..67d9b56 100644
--- a/tools/shared/windows/registry.cpp
+++ b/tools/shared/windows/registry.cpp
@@ -148,7 +148,7 @@ QString readRegistryKey(HKEY parentHandle, const QString &rSubkey)
}
default:
- qWarning("QSettings: unknown data %d type in windows registry", dataType);
+ qWarning("QSettings: unknown data %u type in windows registry", quint32(dataType));
break;
}