forked from qt-creator/qt-creator
Add a toolChainType() method to the ApplicationRunConfiguration.
Best effort only though. This can make detection in the debugger which engine should be used easier. Task-Nr: 256161
This commit is contained in:
@@ -612,6 +612,15 @@ CMakeTarget CMakeProject::targetForTitle(const QString &title)
|
|||||||
return CMakeTarget();
|
return CMakeTarget();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ProjectExplorer::ToolChain::ToolChainType CMakeProject::toolChainType() const
|
||||||
|
{
|
||||||
|
if (m_toolChain)
|
||||||
|
return m_toolChain->type();
|
||||||
|
return ProjectExplorer::ToolChain::UNKNOWN;
|
||||||
|
}
|
||||||
|
|
||||||
|
// CMakeFile
|
||||||
|
|
||||||
CMakeFile::CMakeFile(CMakeProject *parent, QString fileName)
|
CMakeFile::CMakeFile(CMakeProject *parent, QString fileName)
|
||||||
: Core::IFile(parent), m_project(parent), m_fileName(fileName)
|
: Core::IFile(parent), m_project(parent), m_fileName(fileName)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -105,6 +105,7 @@ public:
|
|||||||
CMakeTarget targetForTitle(const QString &title);
|
CMakeTarget targetForTitle(const QString &title);
|
||||||
|
|
||||||
QString sourceDirectory() const;
|
QString sourceDirectory() const;
|
||||||
|
ProjectExplorer::ToolChain::ToolChainType toolChainType() const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void saveSettingsImpl(ProjectExplorer::PersistentSettingsWriter &writer);
|
virtual void saveSettingsImpl(ProjectExplorer::PersistentSettingsWriter &writer);
|
||||||
|
|||||||
@@ -217,6 +217,12 @@ void CMakeRunConfiguration::setUserEnvironmentChanges(const QList<ProjectExplore
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ProjectExplorer::ToolChain::ToolChainType CMakeRunConfiguration::toolChainType() const
|
||||||
|
{
|
||||||
|
CMakeProject *pro = static_cast<CMakeProject *>(project());
|
||||||
|
return pro->toolChainType();
|
||||||
|
}
|
||||||
|
|
||||||
// Configuration widget
|
// Configuration widget
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -70,6 +70,7 @@ public:
|
|||||||
virtual void save(ProjectExplorer::PersistentSettingsWriter &writer) const;
|
virtual void save(ProjectExplorer::PersistentSettingsWriter &writer) const;
|
||||||
virtual void restore(const ProjectExplorer::PersistentSettingsReader &reader);
|
virtual void restore(const ProjectExplorer::PersistentSettingsReader &reader);
|
||||||
virtual QString dumperLibrary() const;
|
virtual QString dumperLibrary() const;
|
||||||
|
virtual ProjectExplorer::ToolChain::ToolChainType toolChainType() const;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void baseEnvironmentChanged();
|
void baseEnvironmentChanged();
|
||||||
|
|||||||
@@ -30,6 +30,8 @@
|
|||||||
#ifndef APPLICATIONRUNCONFIGURATION_H
|
#ifndef APPLICATIONRUNCONFIGURATION_H
|
||||||
#define APPLICATIONRUNCONFIGURATION_H
|
#define APPLICATIONRUNCONFIGURATION_H
|
||||||
|
|
||||||
|
#include <projectexplorer/toolchain.h>
|
||||||
|
|
||||||
#include "runconfiguration.h"
|
#include "runconfiguration.h"
|
||||||
#include "applicationlauncher.h"
|
#include "applicationlauncher.h"
|
||||||
|
|
||||||
@@ -55,6 +57,7 @@ public:
|
|||||||
virtual QStringList commandLineArguments() const = 0;
|
virtual QStringList commandLineArguments() const = 0;
|
||||||
virtual Environment environment() const = 0;
|
virtual Environment environment() const = 0;
|
||||||
virtual QString dumperLibrary() const = 0;
|
virtual QString dumperLibrary() const = 0;
|
||||||
|
virtual ProjectExplorer::ToolChain::ToolChainType toolChainType() const = 0;
|
||||||
|
|
||||||
virtual void save(PersistentSettingsWriter &writer) const;
|
virtual void save(PersistentSettingsWriter &writer) const;
|
||||||
virtual void restore(const PersistentSettingsReader &reader);
|
virtual void restore(const PersistentSettingsReader &reader);
|
||||||
|
|||||||
@@ -459,6 +459,10 @@ QString CustomExecutableRunConfiguration::dumperLibrary() const
|
|||||||
return ProjectExplorer::DebuggingHelperLibrary::debuggingHelperLibrary(qmakePath);
|
return ProjectExplorer::DebuggingHelperLibrary::debuggingHelperLibrary(qmakePath);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ProjectExplorer::ToolChain::ToolChainType CustomExecutableRunConfiguration::toolChainType() const
|
||||||
|
{
|
||||||
|
return ProjectExplorer::ToolChain::UNKNOWN;
|
||||||
|
}
|
||||||
|
|
||||||
// Factory
|
// Factory
|
||||||
|
|
||||||
|
|||||||
@@ -90,6 +90,8 @@ public:
|
|||||||
virtual QWidget *configurationWidget();
|
virtual QWidget *configurationWidget();
|
||||||
virtual QString dumperLibrary() const;
|
virtual QString dumperLibrary() const;
|
||||||
|
|
||||||
|
virtual ProjectExplorer::ToolChain::ToolChainType toolChainType() const;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void changed();
|
void changed();
|
||||||
|
|
||||||
|
|||||||
@@ -74,6 +74,7 @@ public:
|
|||||||
MSVC,
|
MSVC,
|
||||||
WINCE,
|
WINCE,
|
||||||
OTHER,
|
OTHER,
|
||||||
|
UNKNOWN,
|
||||||
INVALID
|
INVALID
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -635,6 +635,11 @@ Qt4RunConfiguration::BaseEnvironmentBase Qt4RunConfiguration::baseEnvironmentBas
|
|||||||
{
|
{
|
||||||
return m_baseEnvironmentBase;
|
return m_baseEnvironmentBase;
|
||||||
}
|
}
|
||||||
|
ProjectExplorer::ToolChain::ToolChainType Qt4RunConfiguration::toolChainType() const
|
||||||
|
{
|
||||||
|
Qt4Project *pro = qobject_cast<Qt4Project *>(project());
|
||||||
|
return pro->qtVersion(pro->activeBuildConfiguration())->toolchainType();
|
||||||
|
}
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Qt4RunConfigurationFactory
|
/// Qt4RunConfigurationFactory
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ public:
|
|||||||
virtual QStringList commandLineArguments() const;
|
virtual QStringList commandLineArguments() const;
|
||||||
virtual ProjectExplorer::Environment environment() const;
|
virtual ProjectExplorer::Environment environment() const;
|
||||||
virtual QString dumperLibrary() const;
|
virtual QString dumperLibrary() const;
|
||||||
|
virtual ProjectExplorer::ToolChain::ToolChainType toolChainType() const;
|
||||||
|
|
||||||
bool isUsingDyldImageSuffix() const;
|
bool isUsingDyldImageSuffix() const;
|
||||||
void setUsingDyldImageSuffix(bool state);
|
void setUsingDyldImageSuffix(bool state);
|
||||||
|
|||||||
Reference in New Issue
Block a user