Commit e2c06d5d authored by Daniel Molkentin's avatar Daniel Molkentin
Browse files

Make conversion to from QTDIR to qmake more reliable.

parent 9960bea8
......@@ -102,12 +102,20 @@ QtVersionManager::QtVersionManager()
if (isAutodetected)
autodetectionSource = QLatin1String(PATH_AUTODETECTION_SOURCE);
}
QString qmakePath = s->value("QMakePath").toString();
if (qmakePath.isEmpty()) {
QString path = s->value("Path").toString();
if (!path.isEmpty())
qmakePath = + "/bin/qmake.exe";
if (!path.isEmpty()) {
foreach(const QString& command, ProjectExplorer::DebuggingHelperLibrary::possibleQMakeCommands())
{
QFileInfo fi(path + "/bin/" + command);
if (fi.exists())
{
qmakePath = fi.filePath();
break;
}
}
}
}
QtVersion *version = new QtVersion(s->value("Name").toString(),
qmakePath,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment