Changeset View
Changeset View
Standalone View
Standalone View
plugins/custom-definesandincludes/compilerprovider/msvccompiler.cpp
Show All 28 Lines | |||||
29 | #include <QProcessEnvironment> | 29 | #include <QProcessEnvironment> | ||
30 | 30 | | |||
31 | #include <KProcess> | 31 | #include <KProcess> | ||
32 | 32 | | |||
33 | #include <debug.h> | 33 | #include <debug.h> | ||
34 | 34 | | |||
35 | using namespace KDevelop; | 35 | using namespace KDevelop; | ||
36 | 36 | | |||
37 | Defines MsvcCompiler::defines(const QString&) const | 37 | Defines MsvcCompiler::defines(Utils::LanguageType, const QString&) const | ||
38 | { | 38 | { | ||
39 | Defines ret; | 39 | Defines ret; | ||
40 | //Get standard macros from kdevmsvcdefinehelpers | 40 | //Get standard macros from kdevmsvcdefinehelpers | ||
41 | KProcess proc; | 41 | KProcess proc; | ||
42 | proc.setOutputChannelMode( KProcess::MergedChannels ); | 42 | proc.setOutputChannelMode( KProcess::MergedChannels ); | ||
43 | proc.setTextModeEnabled( true ); | 43 | proc.setTextModeEnabled( true ); | ||
44 | 44 | | |||
45 | // we want to use kdevmsvcdefinehelper as a pseudo compiler backend which | 45 | // we want to use kdevmsvcdefinehelper as a pseudo compiler backend which | ||
▲ Show 20 Lines • Show All 64 Lines • ▼ Show 20 Line(s) | |||||
110 | { | 110 | { | ||
111 | ret[QStringLiteral("__inline")] = QLatin1String(""); | 111 | ret[QStringLiteral("__inline")] = QLatin1String(""); | ||
112 | ret[QStringLiteral("__forceinline")] = QLatin1String(""); | 112 | ret[QStringLiteral("__forceinline")] = QLatin1String(""); | ||
113 | } | 113 | } | ||
114 | 114 | | |||
115 | return ret; | 115 | return ret; | ||
116 | } | 116 | } | ||
117 | 117 | | |||
118 | Path::List MsvcCompiler::includes(const QString&) const | 118 | Path::List MsvcCompiler::includes(Utils::LanguageType, const QString&) const | ||
119 | { | 119 | { | ||
120 | QStringList _includePaths = QProcessEnvironment::systemEnvironment().value( QStringLiteral("INCLUDE") ).split( QStringLiteral(";"), QString::SkipEmptyParts ); | 120 | QStringList _includePaths = QProcessEnvironment::systemEnvironment().value( QStringLiteral("INCLUDE") ).split( QStringLiteral(";"), QString::SkipEmptyParts ); | ||
121 | Path::List includePaths; | 121 | Path::List includePaths; | ||
122 | foreach( const QString &include, _includePaths ) { | 122 | foreach( const QString &include, _includePaths ) { | ||
123 | includePaths.append( Path( QDir::fromNativeSeparators( include ) ) ); | 123 | includePaths.append( Path( QDir::fromNativeSeparators( include ) ) ); | ||
124 | } | 124 | } | ||
125 | return includePaths; | 125 | return includePaths; | ||
126 | } | 126 | } | ||
127 | 127 | | |||
128 | MsvcCompiler::MsvcCompiler(const QString& name, const QString& path, bool editable, const QString& factoryName): | 128 | MsvcCompiler::MsvcCompiler(const QString& name, const QString& path, bool editable, const QString& factoryName): | ||
129 | ICompiler(name, path, factoryName, editable) | 129 | ICompiler(name, path, factoryName, editable) | ||
130 | {} | 130 | {} |