Commit f8aaa2e0 authored by Tobias Hunger's avatar Tobias Hunger Committed by Tim Jenssen

qmake: Do not rely an rootProjectNode in QmakeProFile::buildDir

Change-Id: I68211110c84587376079c02e0a7cd5f6ac6f9295
Reviewed-by: Tim Jenssen's avatarTim Jenssen <tim.jenssen@qt.io>
parent ea239676
...@@ -1961,7 +1961,7 @@ QString QmakeProFile::sourceDir() const ...@@ -1961,7 +1961,7 @@ QString QmakeProFile::sourceDir() const
QString QmakeProFile::buildDir(QmakeBuildConfiguration *bc) const QString QmakeProFile::buildDir(QmakeBuildConfiguration *bc) const
{ {
const QDir srcDirRoot = m_project->rootProjectNode()->sourceDir(); const QDir srcDirRoot = QDir(m_project->projectDirectory().toString());
const QString relativeDir = srcDirRoot.relativeFilePath(directoryPath().toString()); const QString relativeDir = srcDirRoot.relativeFilePath(directoryPath().toString());
if (!bc && m_project->activeTarget()) if (!bc && m_project->activeTarget())
bc = static_cast<QmakeBuildConfiguration *>(m_project->activeTarget()->activeBuildConfiguration()); bc = static_cast<QmakeBuildConfiguration *>(m_project->activeTarget()->activeBuildConfiguration());
......
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