blob: 48a60138be9b17d4c9d06d2774cb7a0aa54edaa5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "genericmakestep.h"
#include "genericprojectconstants.h"
#include <projectexplorer/makestep.h>
#include <projectexplorer/buildsteplist.h>
#include <projectexplorer/projectexplorerconstants.h>
using namespace ProjectExplorer;
using namespace Utils;
namespace GenericProjectManager::Internal {
class GenericMakeStep final : public MakeStep
{
public:
GenericMakeStep(BuildStepList *parent, Id id)
: MakeStep(parent, id)
{
setAvailableBuildTargets({"all", "clean"});
if (parent->id() == ProjectExplorer::Constants::BUILDSTEPS_BUILD) {
setSelectedBuildTarget("all");
} else if (parent->id() == ProjectExplorer::Constants::BUILDSTEPS_CLEAN) {
setSelectedBuildTarget("clean");
setIgnoreReturnValue(true);
}
}
};
class GenericMakeStepFactory final : public BuildStepFactory
{
public:
GenericMakeStepFactory()
{
registerStep<GenericMakeStep>(Constants::GENERIC_MS_ID);
setDisplayName(MakeStep::defaultDisplayName());
setSupportedProjectType(Constants::GENERICPROJECT_ID);
}
};
void setupGenericMakeStep()
{
static GenericMakeStepFactory theGenericMakeStepFactory;
}
} // GenericProjectManager::Internal
|