forked from qt-creator/qt-creator
QNX: Use canonicalPath for device detection paths
The QNX paths are constructed from a base path, if the base path is ending in / you can have a path with two // as delimiter. When doing some comparisons the path with / is not the same as the path with //. Change-Id: I335a50d8a9d381a886eb0c3d24b5dca610bd98df Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -367,8 +367,8 @@ void QnxConfiguration::readInformation()
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
foreach (const ConfigInstallInformation &info, installInfoList) {
|
foreach (const ConfigInstallInformation &info, installInfoList) {
|
||||||
if (m_qnxHost == FilePath::fromString(info.host)
|
if (m_qnxHost == FilePath::fromString(info.host).canonicalPath()
|
||||||
&& m_qnxTarget == FilePath::fromString(info.target)) {
|
&& m_qnxTarget == FilePath::fromString(info.target).canonicalPath()) {
|
||||||
m_configName = info.name;
|
m_configName = info.name;
|
||||||
setVersion(QnxVersionNumber(info.version));
|
setVersion(QnxVersionNumber(info.version));
|
||||||
break;
|
break;
|
||||||
@@ -383,11 +383,11 @@ void QnxConfiguration::setDefaultConfiguration(const Utils::FilePath &envScript)
|
|||||||
m_qnxEnv = QnxUtils::qnxEnvironmentFromEnvFile(m_envFile.toString());
|
m_qnxEnv = QnxUtils::qnxEnvironmentFromEnvFile(m_envFile.toString());
|
||||||
foreach (const EnvironmentItem &item, m_qnxEnv) {
|
foreach (const EnvironmentItem &item, m_qnxEnv) {
|
||||||
if (item.name == QNXConfiguration)
|
if (item.name == QNXConfiguration)
|
||||||
m_qnxConfiguration = FilePath::fromString(item.value);
|
m_qnxConfiguration = FilePath::fromString(item.value).canonicalPath();
|
||||||
else if (item.name == QNXTarget)
|
else if (item.name == QNXTarget)
|
||||||
m_qnxTarget = FilePath::fromString(item.value);
|
m_qnxTarget = FilePath::fromString(item.value).canonicalPath();
|
||||||
else if (item.name == QNXHost)
|
else if (item.name == QNXHost)
|
||||||
m_qnxHost = FilePath::fromString(item.value);
|
m_qnxHost = FilePath::fromString(item.value).canonicalPath();
|
||||||
}
|
}
|
||||||
|
|
||||||
FilePath qccPath = FilePath::fromString(HostOsInfo::withExecutableSuffix(
|
FilePath qccPath = FilePath::fromString(HostOsInfo::withExecutableSuffix(
|
||||||
|
Reference in New Issue
Block a user