forked from qt-creator/qt-creator
CMake: Make CMakeParser work again
The CMakeParser used to set relative paths in the Tasks it creates. Since is problematic: Task tries to match that relative file name to one of the files that exist in the session. At the time cmake runs only the top-level CMakeLists.txt file is known, so this logic will map all the relative file paths to that file. Make sure to write absolute file paths into tasks so that this mapping is not attempted. Change-Id: I4ab72df21f18d2eff27ca9a502d605e00df2ad85 Reviewed-by: Cristian Adam <cristian.adam@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -52,9 +52,10 @@
|
||||
#include <utils/qtcprocess.h>
|
||||
#include <utils/pathchooser.h>
|
||||
|
||||
#include <QCheckBox>
|
||||
#include <QDir>
|
||||
#include <QFormLayout>
|
||||
#include <QGroupBox>
|
||||
#include <QCheckBox>
|
||||
#include <QLineEdit>
|
||||
#include <QListWidget>
|
||||
|
||||
@@ -212,7 +213,9 @@ bool CMakeBuildStep::init()
|
||||
pp->setCommandLine(cmakeCommand(rc));
|
||||
pp->resolveAll();
|
||||
|
||||
setOutputParser(new CMakeParser);
|
||||
CMakeParser *cmakeParser = new CMakeParser;
|
||||
cmakeParser->setSourceDirectory(projectDirectory.toString());
|
||||
setOutputParser(cmakeParser);
|
||||
appendOutputParser(new GnuMakeParser);
|
||||
IOutputParser *parser = target()->kit()->createOutputParser();
|
||||
if (parser)
|
||||
|
||||
Reference in New Issue
Block a user