mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Introjucer: added an exporter type for VS2015
This commit is contained in:
parent
80f0219f71
commit
8f8c9cccd4
2 changed files with 49 additions and 4 deletions
|
|
@ -1599,3 +1599,44 @@ public:
|
|||
private:
|
||||
JUCE_DECLARE_NON_COPYABLE (MSVCProjectExporterVC2013)
|
||||
};
|
||||
|
||||
//==============================================================================
|
||||
class MSVCProjectExporterVC2015 : public MSVCProjectExporterVC2012
|
||||
{
|
||||
public:
|
||||
MSVCProjectExporterVC2015 (Project& p, const ValueTree& t)
|
||||
: MSVCProjectExporterVC2012 (p, t, "VisualStudio2015")
|
||||
{
|
||||
name = getName();
|
||||
}
|
||||
|
||||
static const char* getName() { return "Visual Studio 2015"; }
|
||||
static const char* getValueTreeTypeName() { return "VS2015"; }
|
||||
int getVisualStudioVersion() const override { return 14; }
|
||||
String getSolutionComment() const override { return "# Visual Studio 2015"; }
|
||||
String getToolsVersion() const override { return "14.0"; }
|
||||
String getDefaultToolset() const override { return "v140"; }
|
||||
|
||||
static MSVCProjectExporterVC2015* createForSettings (Project& project, const ValueTree& settings)
|
||||
{
|
||||
if (settings.hasType (getValueTreeTypeName()))
|
||||
return new MSVCProjectExporterVC2015 (project, settings);
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void createExporterProperties (PropertyListBuilder& props) override
|
||||
{
|
||||
MSVCProjectExporterBase::createExporterProperties (props);
|
||||
|
||||
static const char* toolsetNames[] = { "(default)", "v140", "v140_xp", nullptr };
|
||||
const var toolsets[] = { var(), "v140", "v140_xp" };
|
||||
|
||||
props.add (new ChoicePropertyComponent (getPlatformToolsetValue(), "Platform Toolset",
|
||||
StringArray (toolsetNames),
|
||||
Array<var> (toolsets, numElementsInArray (toolsets))));
|
||||
}
|
||||
|
||||
private:
|
||||
JUCE_DECLARE_NON_COPYABLE (MSVCProjectExporterVC2015)
|
||||
};
|
||||
|
|
|
|||
|
|
@ -42,6 +42,7 @@ StringArray ProjectExporter::getExporterNames()
|
|||
s.add (MSVCProjectExporterVC2010::getName());
|
||||
s.add (MSVCProjectExporterVC2012::getName());
|
||||
s.add (MSVCProjectExporterVC2013::getName());
|
||||
s.add (MSVCProjectExporterVC2015::getName());
|
||||
s.add (MakefileProjectExporter::getNameLinux());
|
||||
s.add (AndroidProjectExporter::getNameAndroid());
|
||||
s.add (CodeBlocksProjectExporter::getNameCodeBlocks());
|
||||
|
|
@ -74,9 +75,10 @@ ProjectExporter* ProjectExporter::createNewExporter (Project& project, const int
|
|||
case 4: exp = new MSVCProjectExporterVC2010 (project, ValueTree (MSVCProjectExporterVC2010::getValueTreeTypeName())); break;
|
||||
case 5: exp = new MSVCProjectExporterVC2012 (project, ValueTree (MSVCProjectExporterVC2012::getValueTreeTypeName())); break;
|
||||
case 6: exp = new MSVCProjectExporterVC2013 (project, ValueTree (MSVCProjectExporterVC2013::getValueTreeTypeName())); break;
|
||||
case 7: exp = new MakefileProjectExporter (project, ValueTree (MakefileProjectExporter ::getValueTreeTypeName())); break;
|
||||
case 8: exp = new AndroidProjectExporter (project, ValueTree (AndroidProjectExporter ::getValueTreeTypeName())); break;
|
||||
case 9: exp = new CodeBlocksProjectExporter (project, ValueTree (CodeBlocksProjectExporter::getValueTreeTypeName())); break;
|
||||
case 7: exp = new MSVCProjectExporterVC2015 (project, ValueTree (MSVCProjectExporterVC2015::getValueTreeTypeName())); break;
|
||||
case 8: exp = new MakefileProjectExporter (project, ValueTree (MakefileProjectExporter ::getValueTreeTypeName())); break;
|
||||
case 9: exp = new AndroidProjectExporter (project, ValueTree (AndroidProjectExporter ::getValueTreeTypeName())); break;
|
||||
case 10: exp = new CodeBlocksProjectExporter (project, ValueTree (CodeBlocksProjectExporter::getValueTreeTypeName())); break;
|
||||
|
||||
default: jassertfalse; return 0;
|
||||
}
|
||||
|
|
@ -99,6 +101,7 @@ ProjectExporter* ProjectExporter::createExporter (Project& project, const ValueT
|
|||
if (exp == nullptr) exp = MSVCProjectExporterVC2010::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = MSVCProjectExporterVC2012::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = MSVCProjectExporterVC2013::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = MSVCProjectExporterVC2015::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = XCodeProjectExporter ::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = MakefileProjectExporter ::createForSettings (project, settings);
|
||||
if (exp == nullptr) exp = AndroidProjectExporter ::createForSettings (project, settings);
|
||||
|
|
@ -123,6 +126,7 @@ bool ProjectExporter::canProjectBeLaunched (Project* project)
|
|||
MSVCProjectExporterVC2010::getValueTreeTypeName(),
|
||||
MSVCProjectExporterVC2012::getValueTreeTypeName(),
|
||||
MSVCProjectExporterVC2013::getValueTreeTypeName(),
|
||||
MSVCProjectExporterVC2015::getValueTreeTypeName(),
|
||||
#elif JUCE_LINUX
|
||||
// (this doesn't currently launch.. not really sure what it would do on linux)
|
||||
//MakefileProjectExporter::getValueTreeTypeName(),
|
||||
|
|
@ -695,4 +699,4 @@ String ProjectExporter::getExternalLibraryFlags (const BuildConfiguration& confi
|
|||
return replacePreprocessorTokens (config, "-l" + libraries.joinIntoString (" -l")).trim();
|
||||
|
||||
return String::empty;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue