CMake: Collect also remote filenames from generateBuildTargets()

QDir::cleanPath(...) doesn't do the right thing on stringified
Utils::FilePaths. Use FilePath functions instead.

Change-Id: Ied66f38dd30a15694bce12ed57d37411bb87f680
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
hjk
2021-06-09 17:05:50 +02:00
parent 0e6a4e757c
commit e35235ea72
3 changed files with 16 additions and 13 deletions

View File

@@ -997,6 +997,13 @@ FilePath FilePath::absoluteFilePath() const
return result;
}
FilePath FilePath::absoluteFilePath(const FilePath &tail) const
{
if (FileUtils::isRelativePath(tail.m_data))
return pathAppended(tail.m_data);
return tail;
}
/// Constructs an absolute FilePath from this path which
/// is interpreted as being relative to \a anchor.
FilePath FilePath::absoluteFromRelativePath(const FilePath &anchor) const