Commit b1a121c5 authored by dt's avatar dt
Browse files

Progress so far

parent e4d5d004
......@@ -965,7 +965,7 @@ static QString msgEngineNotAvailable(const char *engine)
static IDebuggerEngine *debuggerEngineForToolChain(int toolChainType)
{
switch (toolChainType) {
//case ProjectExplorer::ToolChain::LinuxICC:
case ProjectExplorer::ToolChain::LINUX_ICC:
case ProjectExplorer::ToolChain::MinGW:
case ProjectExplorer::ToolChain::GCC:
return gdbEngine;
......@@ -1885,7 +1885,7 @@ bool DebuggerManager::checkDebugConfiguration(int toolChain,
bool success = true;
switch(toolChain) {
case ProjectExplorer::ToolChain::GCC:
//case ProjectExplorer::ToolChain::LinuxICC:
case ProjectExplorer::ToolChain::LINUX_ICC:
case ProjectExplorer::ToolChain::MinGW:
case ProjectExplorer::ToolChain::WINCE: // S60
case ProjectExplorer::ToolChain::WINSCW:
......
......@@ -348,10 +348,11 @@ void GenericProject::setToolChainType(ProjectExplorer::ToolChain::ToolChainType
} else if (type == ToolChain::WINCE) {
const QString msvcVersion, wincePlatform; // ### FIXME
m_toolChain = ToolChain::createWinCEToolChain(msvcVersion, wincePlatform);
} else if (type == ToolChain::GCC || type == ToolChain::GCC) {
} else if (type == ToolChain::GCC) {
const QLatin1String qmake_cxx("g++"); // ### FIXME
m_toolChain = ToolChain::createGccToolChain(qmake_cxx);
} else if (type == ToolChain::LINUX_ICC) {
m_toolChain = ToolChain::createLinuxIccToolChain();
}
}
......
......@@ -194,6 +194,9 @@ private slots:
void testGccOutputParsers_data();
void testGccOutputParsers();
void testLinuxIccOutputParsers_data();
void testLinuxIccOutputParsers();
void testGnuMakeParserParsing_data();
void testGnuMakeParserParsing();
void testGnuMakeParserTaskMangling_data();
......
......@@ -77,7 +77,8 @@ HEADERS += projectexplorer.h \
doubletabwidget.h \
addtargetdialog.h \
buildenvironmentwidget.h \
buildconfigdialog.h
buildconfigdialog.h \
linuxiccparser.h
SOURCES += projectexplorer.cpp \
projectwindow.cpp \
buildmanager.cpp \
......@@ -141,7 +142,8 @@ SOURCES += projectexplorer.cpp \
doubletabwidget.cpp \
addtargetdialog.cpp \
buildenvironmentwidget.cpp \
buildconfigdialog.cpp
buildconfigdialog.cpp \
linuxiccparser.cpp
FORMS += processstep.ui \
editorsettingspropertiespage.ui \
runsettingspropertiespage.ui \
......
......@@ -33,6 +33,7 @@
#include "projectexplorersettings.h"
#include "gccparser.h"
#include "msvcparser.h"
#include "linuxiccparser.h"
#include <QtCore/QDebug>
#include <QtCore/QFileInfo>
......@@ -83,6 +84,11 @@ ToolChain *ToolChain::createMinGWToolChain(const QString &gcc, const QString &mi
return new MinGWToolChain(gcc, mingwPath);
}
ToolChain *ToolChain::createLinuxIccToolChain()
{
return new LinuxIccToolChain();
}
ToolChain *ToolChain::createMSVCToolChain(const QString &name, bool amd64)
{
return MSVCToolChain::create(name, amd64);
......@@ -124,8 +130,8 @@ QString ToolChain::toolChainName(ToolChainType tc)
switch (tc) {
case GCC:
return QCoreApplication::translate("ToolChain", "GCC");
// case LinuxICC:
// return QCoreApplication::translate("ToolChain", "Intel C++ Compiler (Linux)");
case LINUX_ICC:
return QCoreApplication::translate("ToolChain", "Intel C++ Compiler (Linux)");
case MinGW:
return QString::fromLatin1("MinGW");
case MSVC:
......@@ -319,6 +325,21 @@ IOutputParser *MinGWToolChain::outputParser() const
return new GccParser;
}
LinuxIccToolChain::LinuxIccToolChain()
: GccToolChain(QLatin1String("icpc"))
{
}
ToolChain::ToolChainType LinuxIccToolChain::type() const
{
return ToolChain::LINUX_ICC;
}
IOutputParser *LinuxIccToolChain::outputParser() const
{
return new LinuxIccParser;
}
// ---------------- MSVC installation location code
// Format the name of an SDK or VC installation version with platform
......
......@@ -76,7 +76,7 @@ public:
enum ToolChainType
{
GCC = 0,
// LINUX_ICC = 1,
LINUX_ICC = 1,
MinGW = 2,
MSVC = 3,
WINCE = 4,
......@@ -107,6 +107,7 @@ public:
// Factory methods
static ToolChain *createGccToolChain(const QString &gcc);
static ToolChain *createMinGWToolChain(const QString &gcc, const QString &mingwPath);
static ToolChain *createLinuxIccToolChain();
static ToolChain *createMSVCToolChain(const QString &name, bool amd64);
static ToolChain *createWinCEToolChain(const QString &name, const QString &platform);
static QStringList availableMSVCVersions();
......@@ -157,6 +158,15 @@ private:
QString m_mingwPath;
};
class PROJECTEXPLORER_EXPORT LinuxIccToolChain : public GccToolChain
{
public:
LinuxIccToolChain();
virtual ToolChainType type() const;
virtual IOutputParser *outputParser() const;
};
// TODO some stuff needs to be moved into this
class PROJECTEXPLORER_EXPORT MSVCToolChain : public ToolChain
{
......
......@@ -142,6 +142,7 @@ bool Qt4RunConfiguration::isEnabled(ProjectExplorer::BuildConfiguration *configu
case ToolChain::GCC: case ToolChain::MinGW:
case ToolChain::GCCE_GNUPOC: case ToolChain::RVCT_ARMV5_GNUPOC:
case ToolChain::OTHER: case ToolChain::UNKNOWN:
case ToolChain::LINUX_ICC:
case ToolChain::INVALID:
enabled = true;
break;
......
......@@ -1305,17 +1305,20 @@ void QtVersion::updateToolChainAndMkspec() const
m_toolChains << ToolChainPtr(
ProjectExplorer::ToolChain::createMinGWToolChain(qmakeCXX, mingwDirectory()));
m_targetIds.insert(QLatin1String(Constants::DESKTOP_TARGET_ID));
} else if (qmakeCXX == "g++" || qmakeCXX == "icc") {
} else if (qmakeCXX == "g++") {
ProjectExplorer::Environment env = ProjectExplorer::Environment::systemEnvironment();
//addToEnvironment(env);
qmakeCXX = env.searchInPath(qmakeCXX);
if (qmakeCXX.isEmpty()) {
// macx-xcode mkspec resets the value of QMAKE_CXX.
// Unfortunately, we need a valid QMAKE_CXX to configure the parser.
qmakeCXX = QLatin1String("cc");
}
qmakeCXX = env.searchInPath(qmakeCXX);
m_toolChains << ToolChainPtr(ProjectExplorer::ToolChain::createGccToolChain(qmakeCXX));
m_targetIds.insert(QLatin1String(Constants::DESKTOP_TARGET_ID));
} else if (qmakeCXX == "icpc") {
m_toolChains << ToolChainPtr(ProjectExplorer::ToolChain::createLinuxIccToolChain());
m_targetIds.insert(QLatin1String(Constants::DESKTOP_TARGET_ID));
}
if (m_toolChains.isEmpty()) {
......
Supports Markdown
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