From 28df27d924bb407791a76de8159c9ffa6efde283 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Mon, 3 Jun 2013 19:22:23 +0200 Subject: [PATCH] update m_featureRoots less aggressively MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit it's not necessary to immediately re-calculate the roots after assigning QMAKE_PLATFORM - it's sufficient to do it on-demand, so merely invalidate them. this avoids that we re-calculate them multiple times without ever using them in between while processing specs with distributed platform assignments. Change-Id: If508594764811b96a577fc81c5ded34ab0453148 Reviewed-by: Tor Arne Vestbø --- src/shared/proparser/qmakeevaluator.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/shared/proparser/qmakeevaluator.cpp b/src/shared/proparser/qmakeevaluator.cpp index 067384a6826..db6af6f7308 100644 --- a/src/shared/proparser/qmakeevaluator.cpp +++ b/src/shared/proparser/qmakeevaluator.cpp @@ -922,7 +922,7 @@ void QMakeEvaluator::visitProVariable( if (varName == statics.strTEMPLATE) setTemplate(); else if (varName == statics.strQMAKE_PLATFORM) - updateFeaturePaths(); + m_featureRoots = 0; #ifdef PROEVALUATOR_FULL else if (varName == statics.strREQUIRES) checkRequirements(values(varName)); @@ -1146,6 +1146,7 @@ bool QMakeEvaluator::loadSpecInternal() #endif valuesRef(ProKey("QMAKESPEC")) << ProString(m_qmakespec); m_qmakespecName = IoUtils::fileName(m_qmakespec).toString(); + // This also ensures that m_featureRoots is valid. if (evaluateFeatureFile(QLatin1String("spec_post.prf")) != ReturnTrue) return false; // The MinGW and x-build specs may change the separator; $$shell_{path,quote}() need it