ProjectExplorer: Handle Macros in build directory

Macros in build directory were not consistently expanded, so building
failed (at least in qmake projects).

Task-number: QTCREATORBUG-18601
Change-Id: I7ab06a1b969866748cf4062d1c820e5830efe281
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Tobias Hunger
2017-11-03 15:23:40 +01:00
parent 19e125ce5f
commit 03e629e5f9

View File

@@ -119,7 +119,7 @@ void BuildConfiguration::ctor()
Utils::FileName BuildConfiguration::buildDirectory() const Utils::FileName BuildConfiguration::buildDirectory() const
{ {
QString path = QDir::cleanPath(environment().expandVariables(m_buildDirectory.toString())); const QString path = macroExpander()->expand(QDir::cleanPath(environment().expandVariables(m_buildDirectory.toString())));
return Utils::FileName::fromString(QDir::cleanPath(QDir(target()->project()->projectDirectory().toString()).absoluteFilePath(path))); return Utils::FileName::fromString(QDir::cleanPath(QDir(target()->project()->projectDirectory().toString()).absoluteFilePath(path)));
} }