From: Orgad Shaneh Date: Tue, 9 Oct 2012 08:17:43 +0000 (+0200) Subject: QMakeEvaluator: Set pro file as source for internal variables X-Git-Tag: accepted/tizen/20131212.181521~100^2~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f8cd4b981041c1cb68355b4ce7f38a4397dc208e;p=platform%2Fupstream%2Fqttools.git QMakeEvaluator: Set pro file as source for internal variables Task-number: QTCREATORBUG-7006 Change-Id: I3f599f92d03b6f9fdf65b12cf4090e28cc497fbd Reviewed-by: Oswald Buddenhagen (cherry picked from qtcreator/6e3af2bf2e2833e0ecbc9b366af8e06abd7ecf96) Reviewed-by: Orgad Shaneh Reviewed-by: hjk --- diff --git a/src/linguist/shared/qmakeevaluator.cpp b/src/linguist/shared/qmakeevaluator.cpp index 06dff33..98f3018 100644 --- a/src/linguist/shared/qmakeevaluator.cpp +++ b/src/linguist/shared/qmakeevaluator.cpp @@ -1239,10 +1239,11 @@ void QMakeEvaluator::setupProject() { setTemplate(); ProValueMap &vars = m_valuemapStack.top(); - vars[ProKey("TARGET")] << ProString(QFileInfo(currentFileName()).baseName()); - vars[ProKey("_PRO_FILE_")] << ProString(currentFileName()); - vars[ProKey("_PRO_FILE_PWD_")] << ProString(currentDirectory()); - vars[ProKey("OUT_PWD")] << ProString(m_outputDir); + ProFile *proFile = currentProFile(); + vars[ProKey("TARGET")] << ProString(QFileInfo(currentFileName()).baseName()).setSource(proFile); + vars[ProKey("_PRO_FILE_")] << ProString(currentFileName()).setSource(proFile); + vars[ProKey("_PRO_FILE_PWD_")] << ProString(currentDirectory()).setSource(proFile); + vars[ProKey("OUT_PWD")] << ProString(m_outputDir).setSource(proFile); } void QMakeEvaluator::evaluateCommand(const QString &cmds, const QString &where)