Profile introduction

Introduce Profiles to store sets of values that describe a system/device.

These profiles are held by a target, getting rid of much of the information
stored in the Build-/Run-/DeployConfigurations, greatly simplifying those.

This is a squash of the wip/profile branch which has been on gerrit for a
while, rebased to current master.

Change-Id: I25956c8dd4d1962b2134bfaa8a8076ae3909460f
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
This commit is contained in:
Tobias Hunger
2012-04-24 15:49:09 +02:00
parent 8c77b8c9d7
commit 2431456216
379 changed files with 12690 additions and 14437 deletions

View File

@@ -34,11 +34,11 @@
#include "autoreconfstep.h"
#include "autotoolsproject.h"
#include "autotoolstarget.h"
#include "autotoolsbuildconfiguration.h"
#include "autotoolsprojectconstants.h"
#include <projectexplorer/buildsteplist.h>
#include <projectexplorer/target.h>
#include <projectexplorer/toolchain.h>
#include <projectexplorer/gnumakeparser.h>
#include <projectexplorer/projectexplorer.h>
@@ -66,9 +66,9 @@ AutoreconfStepFactory::AutoreconfStepFactory(QObject *parent) :
QList<Core::Id> AutoreconfStepFactory::availableCreationIds(BuildStepList *parent) const
{
if (parent->target()->project()->id() == Core::Id(Constants::AUTOTOOLS_PROJECT_ID))
return QList<Core::Id>() << Core::Id(AUTORECONF_STEP_ID);
return QList<Core::Id>();
if (!canHandle(parent))
return QList<Core::Id>();
return QList<Core::Id>() << Core::Id(AUTORECONF_STEP_ID);
}
QString AutoreconfStepFactory::displayNameForId(const Core::Id id) const
@@ -80,13 +80,7 @@ QString AutoreconfStepFactory::displayNameForId(const Core::Id id) const
bool AutoreconfStepFactory::canCreate(BuildStepList *parent, const Core::Id id) const
{
if (parent->target()->project()->id() != Core::Id(Constants::AUTOTOOLS_PROJECT_ID))
return false;
if (parent->id() != Core::Id(ProjectExplorer::Constants::BUILDSTEPS_BUILD))
return false;
return Core::Id(AUTORECONF_STEP_ID) == id;
return canHandle(parent) && Core::Id(AUTORECONF_STEP_ID) == id;
}
BuildStep *AutoreconfStepFactory::create(BuildStepList *parent, const Core::Id id)
@@ -124,6 +118,13 @@ BuildStep *AutoreconfStepFactory::restore(BuildStepList *parent, const QVariantM
return 0;
}
bool AutoreconfStepFactory::canHandle(BuildStepList *parent) const
{
if (parent->target()->project()->id() != Core::Id(Constants::AUTOTOOLS_PROJECT_ID))
return false;
return parent->id() == Core::Id(ProjectExplorer::Constants::BUILDSTEPS_BUILD);
}
/////////////////////////
// AutoreconfStep class
/////////////////////////