Commit aa94bee7 authored by Tor Arne Vestbø's avatar Tor Arne Vestbø Committed by Oswald Buddenhagen
Browse files

qmake: Load extra variables only if also loading pre-files



The extra variables only need to be applied once, when we
are loading the pro file (and hence are loding pre files),
not for every single pri/prf that's loaded as a result of that
(which do not load pre files themselves).

Change-Id: I3118694a8eeccf2dc32c4f62df754033fad13528
Reviewed-by: default avatarOswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qtbase/8e7dc25380dceebca094e092d9feb21ad167ba91)
Reviewed-by: default avatarDaniel Teske <daniel.teske@digia.com>
parent dd2425eb
......@@ -1358,10 +1358,6 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::visitProFile(
loadDefaults();
}
for (ProValueMap::ConstIterator it = m_extraVars.constBegin();
it != m_extraVars.constEnd(); ++it)
m_valuemapStack.first().insert(it.key(), it.value());
VisitReturn vr;
m_handler->aboutToEval(currentProFile(), pro, type);
......@@ -1370,6 +1366,10 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::visitProFile(
if (flags & LoadPreFiles) {
setupProject();
for (ProValueMap::ConstIterator it = m_extraVars.constBegin();
it != m_extraVars.constEnd(); ++it)
m_valuemapStack.first().insert(it.key(), it.value());
if ((vr = evaluateFeatureFile(QLatin1String("default_pre.prf"))) == ReturnError)
goto failed;
......
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