parent
e1c1ab7197
commit
50759a9ed3
|
@ -303,6 +303,8 @@ IF (WIN32)
|
|||
cmLocalVisualStudio10Generator.h
|
||||
cmGlobalVisualStudio10Generator.h
|
||||
cmGlobalVisualStudio10Generator.cxx
|
||||
cmGlobalVisualStudio10Win64Generator.h
|
||||
cmGlobalVisualStudio10Win64Generator.cxx
|
||||
cmGlobalVisualStudioGenerator.cxx
|
||||
cmGlobalVisualStudioGenerator.h
|
||||
cmGlobalWatcomWMakeGenerator.cxx
|
||||
|
|
|
@ -37,7 +37,8 @@ void cmGlobalVisualStudio10Generator::WriteSLNHeader(std::ostream& fout)
|
|||
///! Create a local generator appropriate to this Global Generator
|
||||
cmLocalGenerator *cmGlobalVisualStudio10Generator::CreateLocalGenerator()
|
||||
{
|
||||
cmLocalGenerator*lg = new cmLocalVisualStudio10Generator;
|
||||
cmLocalVisualStudio10Generator* lg = new cmLocalVisualStudio10Generator;
|
||||
lg->SetPlatformName(this->PlatformName.c_str());
|
||||
lg->SetGlobalGenerator(this);
|
||||
return lg;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,37 @@
|
|||
/*============================================================================
|
||||
CMake - Cross Platform Makefile Generator
|
||||
Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
|
||||
|
||||
Distributed under the OSI-approved BSD License (the "License");
|
||||
see accompanying file Copyright.txt for details.
|
||||
|
||||
This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
See the License for more information.
|
||||
============================================================================*/
|
||||
#include "cmGlobalVisualStudio10Win64Generator.h"
|
||||
#include "cmMakefile.h"
|
||||
#include "cmake.h"
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
cmGlobalVisualStudio10Win64Generator::cmGlobalVisualStudio10Win64Generator()
|
||||
{
|
||||
this->PlatformName = "x64";
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
void cmGlobalVisualStudio10Win64Generator
|
||||
::GetDocumentation(cmDocumentationEntry& entry) const
|
||||
{
|
||||
entry.Name = this->GetName();
|
||||
entry.Brief = "Generates Visual Studio 10 Win64 project files.";
|
||||
entry.Full = "";
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
void cmGlobalVisualStudio10Win64Generator::EnableLanguage(
|
||||
std::vector<std::string> const& lang, cmMakefile *mf, bool optional)
|
||||
{
|
||||
mf->AddDefinition("CMAKE_FORCE_WIN64", "TRUE");
|
||||
cmGlobalVisualStudio10Generator::EnableLanguage(lang, mf, optional);
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
/*============================================================================
|
||||
CMake - Cross Platform Makefile Generator
|
||||
Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
|
||||
|
||||
Distributed under the OSI-approved BSD License (the "License");
|
||||
see accompanying file Copyright.txt for details.
|
||||
|
||||
This software is distributed WITHOUT ANY WARRANTY; without even the
|
||||
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
See the License for more information.
|
||||
============================================================================*/
|
||||
#ifndef cmGlobalVisualStudio10Win64Generator_h
|
||||
#define cmGlobalVisualStudio10Win64Generator_h
|
||||
|
||||
#include "cmGlobalVisualStudio10Generator.h"
|
||||
|
||||
class cmGlobalVisualStudio10Win64Generator :
|
||||
public cmGlobalVisualStudio10Generator
|
||||
{
|
||||
public:
|
||||
cmGlobalVisualStudio10Win64Generator();
|
||||
static cmGlobalGenerator* New() {
|
||||
return new cmGlobalVisualStudio10Win64Generator; }
|
||||
|
||||
///! Get the name for the generator.
|
||||
virtual const char* GetName() const {
|
||||
return cmGlobalVisualStudio10Win64Generator::GetActualName();}
|
||||
static const char* GetActualName() {return "Visual Studio 10 Win64";}
|
||||
|
||||
/** Get the documentation entry for this generator. */
|
||||
virtual void GetDocumentation(cmDocumentationEntry& entry) const;
|
||||
|
||||
virtual void EnableLanguage(std::vector<std::string>const& languages,
|
||||
cmMakefile *, bool optional);
|
||||
};
|
||||
#endif
|
|
@ -38,6 +38,8 @@ public:
|
|||
///! Create a local generator appropriate to this Global Generator
|
||||
virtual cmLocalGenerator *CreateLocalGenerator();
|
||||
|
||||
std::string const& GetPlatformName() const { return this->PlatformName; }
|
||||
|
||||
/**
|
||||
* Override Configure and Generate to add the build-system check
|
||||
* target.
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
#include "cmTarget.h"
|
||||
#include "cmMakefile.h"
|
||||
#include "cmVisualStudio10TargetGenerator.h"
|
||||
#include "cmGlobalVisualStudio7Generator.h"
|
||||
#include "cmGlobalVisualStudio10Generator.h"
|
||||
#include <cm_expat.h>
|
||||
#include "cmXMLParser.h"
|
||||
class cmVS10XMLParser : public cmXMLParser
|
||||
|
@ -93,9 +93,9 @@ void cmLocalVisualStudio10Generator::Generate()
|
|||
|
||||
for(cmTargets::iterator l = tgts.begin(); l != tgts.end(); ++l)
|
||||
{
|
||||
cmVisualStudio10TargetGenerator tg(&l->second,
|
||||
(cmGlobalVisualStudio7Generator*)
|
||||
this->GetGlobalGenerator());
|
||||
cmVisualStudio10TargetGenerator tg(
|
||||
&l->second, static_cast<cmGlobalVisualStudio10Generator*>(
|
||||
this->GetGlobalGenerator()));
|
||||
tg.Generate();
|
||||
}
|
||||
this->WriteStampFiles();
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
See the License for more information.
|
||||
============================================================================*/
|
||||
#include "cmVisualStudio10TargetGenerator.h"
|
||||
#include "cmGlobalVisualStudio7Generator.h"
|
||||
#include "cmGlobalVisualStudio10Generator.h"
|
||||
#include "cmTarget.h"
|
||||
#include "cmComputeLinkInformation.h"
|
||||
#include "cmGeneratedFileStream.h"
|
||||
|
@ -32,7 +32,7 @@ static std::string cmVS10EscapeXML(std::string arg)
|
|||
|
||||
cmVisualStudio10TargetGenerator::
|
||||
cmVisualStudio10TargetGenerator(cmTarget* target,
|
||||
cmGlobalVisualStudio7Generator* gg)
|
||||
cmGlobalVisualStudio10Generator* gg)
|
||||
{
|
||||
this->GlobalGenerator = gg;
|
||||
this->Target = target;
|
||||
|
@ -43,7 +43,7 @@ cmVisualStudio10TargetGenerator(cmTarget* target,
|
|||
this->Name = this->Target->GetName();
|
||||
this->GlobalGenerator->CreateGUID(this->Name.c_str());
|
||||
this->GUID = this->GlobalGenerator->GetGUID(this->Name.c_str());
|
||||
this->Platform = "|Win32";
|
||||
this->Platform = gg->GetPlatformName();
|
||||
this->ComputeObjectNames();
|
||||
this->BuildFileStream = 0;
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ void cmVisualStudio10TargetGenerator::WritePlatformConfigTag(
|
|||
(*stream ) << "";
|
||||
(*stream ) << "<" << tag
|
||||
<< " Condition=\"'$(Configuration)|$(Platform)'=='";
|
||||
(*stream ) << config << this->Platform << "'\"";
|
||||
(*stream ) << config << "|" << this->Platform << "'\"";
|
||||
if(attribute)
|
||||
{
|
||||
(*stream ) << attribute;
|
||||
|
@ -141,6 +141,8 @@ void cmVisualStudio10TargetGenerator::Generate()
|
|||
this->WriteString("<SccProjectName />\n", 2);
|
||||
this->WriteString("<SccLocalPath />\n", 2);
|
||||
this->WriteString("<Keyword>Win32Proj</Keyword>\n", 2);
|
||||
this->WriteString("<Platform>", 2);
|
||||
(*this->BuildFileStream) << this->Platform << "</Platform>\n";
|
||||
this->WriteString("</PropertyGroup>\n", 1);
|
||||
this->WriteString("<Import Project="
|
||||
"\"$(VCTargetsPath)\\Microsoft.Cpp.Default.props\" />\n",
|
||||
|
@ -187,10 +189,11 @@ void cmVisualStudio10TargetGenerator::WriteProjectConfigurations()
|
|||
i != configs->end(); ++i)
|
||||
{
|
||||
this->WriteString("<ProjectConfiguration Include=\"", 2);
|
||||
(*this->BuildFileStream ) << *i << this->Platform << "\">\n";
|
||||
(*this->BuildFileStream ) << *i << "|" << this->Platform << "\">\n";
|
||||
this->WriteString("<Configuration>", 3);
|
||||
(*this->BuildFileStream ) << *i << "</Configuration>\n";
|
||||
this->WriteString("<Platform>Win32</Platform>\n", 3);
|
||||
this->WriteString("<Platform>", 3);
|
||||
(*this->BuildFileStream) << this->Platform << "</Platform>\n";
|
||||
this->WriteString("</ProjectConfiguration>\n", 2);
|
||||
}
|
||||
this->WriteString("</ItemGroup>\n", 1);
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
class cmTarget;
|
||||
class cmMakefile;
|
||||
class cmGeneratedFileStream;
|
||||
class cmGlobalVisualStudio7Generator;
|
||||
class cmGlobalVisualStudio10Generator;
|
||||
class cmSourceFile;
|
||||
class cmCustomCommand;
|
||||
class cmLocalVisualStudio7Generator;
|
||||
|
@ -27,7 +27,7 @@ class cmVisualStudio10TargetGenerator
|
|||
{
|
||||
public:
|
||||
cmVisualStudio10TargetGenerator(cmTarget* target,
|
||||
cmGlobalVisualStudio7Generator* gg);
|
||||
cmGlobalVisualStudio10Generator* gg);
|
||||
~cmVisualStudio10TargetGenerator();
|
||||
void Generate();
|
||||
// used by cmVisualStudioGeneratorOptions
|
||||
|
@ -82,7 +82,7 @@ private:
|
|||
std::string Platform;
|
||||
std::string GUID;
|
||||
std::string Name;
|
||||
cmGlobalVisualStudio7Generator* GlobalGenerator;
|
||||
cmGlobalVisualStudio10Generator* GlobalGenerator;
|
||||
cmGeneratedFileStream* BuildFileStream;
|
||||
cmLocalVisualStudio7Generator* LocalGenerator;
|
||||
std::set<cmSourceFile*> SourcesVisited;
|
||||
|
|
|
@ -63,6 +63,7 @@
|
|||
# include "cmGlobalVisualStudio9Generator.h"
|
||||
# include "cmGlobalVisualStudio9Win64Generator.h"
|
||||
# include "cmGlobalVisualStudio10Generator.h"
|
||||
# include "cmGlobalVisualStudio10Win64Generator.h"
|
||||
# include "cmGlobalVisualStudio8Win64Generator.h"
|
||||
# include "cmGlobalBorlandMakefileGenerator.h"
|
||||
# include "cmGlobalNMakeMakefileGenerator.h"
|
||||
|
@ -2364,6 +2365,8 @@ void cmake::AddDefaultGenerators()
|
|||
&cmGlobalVisualStudio7Generator::New;
|
||||
this->Generators[cmGlobalVisualStudio10Generator::GetActualName()] =
|
||||
&cmGlobalVisualStudio10Generator::New;
|
||||
this->Generators[cmGlobalVisualStudio10Win64Generator::GetActualName()] =
|
||||
&cmGlobalVisualStudio10Win64Generator::New;
|
||||
this->Generators[cmGlobalVisualStudio71Generator::GetActualName()] =
|
||||
&cmGlobalVisualStudio71Generator::New;
|
||||
this->Generators[cmGlobalVisualStudio8Generator::GetActualName()] =
|
||||
|
|
Loading…
Reference in New Issue