forked from qt-creator/qt-creator
Nim: Fix running when building with nimble
Change-Id: I62b2eebf408119a19f0e98958e3132c16c9c6aa5 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -25,12 +25,10 @@
|
||||
|
||||
#include "nimblerunconfiguration.h"
|
||||
|
||||
#include "nimbuildsystem.h"
|
||||
#include "nimblebuildsystem.h"
|
||||
#include "nimconstants.h"
|
||||
#include "nimbleproject.h"
|
||||
|
||||
#include <projectexplorer/buildstep.h>
|
||||
#include <projectexplorer/buildsteplist.h>
|
||||
#include <projectexplorer/localenvironmentaspect.h>
|
||||
#include <projectexplorer/runconfigurationaspects.h>
|
||||
#include <projectexplorer/runcontrol.h>
|
||||
@@ -91,14 +89,7 @@ public:
|
||||
NimbleTestConfiguration(ProjectExplorer::Target *target, Utils::Id id)
|
||||
: RunConfiguration(target, id)
|
||||
{
|
||||
QString nimble;
|
||||
auto bc = this->target()->activeBuildConfiguration();
|
||||
auto nimbleBuildStep = bc->buildSteps()->firstStepWithId(Constants::C_NIMBLEBUILDSTEP_ID);
|
||||
if (nimbleBuildStep && nimbleBuildStep->buildSystem()) {
|
||||
nimble = static_cast<NimBuildSystem *>(nimbleBuildStep->buildSystem())->defaultNimble();
|
||||
}
|
||||
|
||||
addAspect<ExecutableAspect>()->setExecutable(Utils::FilePath::fromString(nimble));
|
||||
addAspect<ExecutableAspect>()->setExecutable(Nim::nimblePathFromKit(target->kit()));
|
||||
addAspect<ArgumentsAspect>()->setArguments("test");
|
||||
addAspect<WorkingDirectoryAspect>()->setDefaultWorkingDirectory(project()->projectDirectory());
|
||||
addAspect<TerminalAspect>();
|
||||
|
||||
Reference in New Issue
Block a user