Commit 7c6e2fc0 authored by Christian Kandeler's avatar Christian Kandeler

Toolchains: Small refactoring for better extensibility.

Reviewed-by: Tobias Hunger
parent cab874a2
......@@ -34,7 +34,6 @@
#include "gcctoolchainfactories.h"
#include "gccparser.h"
#include "linuxiccparser.h"
#include "headerpath.h"
#include "projectexplorerconstants.h"
#include "toolchainmanager.h"
......@@ -472,11 +471,15 @@ ToolChainConfigWidget *GccToolChain::configurationWidget()
void GccToolChain::updateSupportedAbis() const
{
if (m_supportedAbis.isEmpty()) {
Utils::Environment env = Utils::Environment::systemEnvironment();
addToEnvironment(env);
m_supportedAbis = guessGccAbi(m_compilerPath, env.toStringList());
}
if (m_supportedAbis.isEmpty())
m_supportedAbis = detectSupportedAbis();
}
QList<Abi> GccToolChain::detectSupportedAbis() const
{
Utils::Environment env = Utils::Environment::systemEnvironment();
addToEnvironment(env);
return guessGccAbi(m_compilerPath, env.toStringList());
}
// --------------------------------------------------------------------------
......
......@@ -90,6 +90,8 @@ protected:
void updateId();
virtual QList<Abi> detectSupportedAbis() const;
mutable QByteArray m_predefinedMacros;
private:
......
......@@ -34,6 +34,7 @@
#define TOOLCHAIN_H
#include "projectexplorer_export.h"
#include "headerpath.h"
#include <QtCore/QObject>
#include <QtCore/QString>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment