VS: Change variable type of ArchitectureId from const char* to string
This commit is contained in:
parent
332dc09d0d
commit
102521b6b3
|
@ -144,8 +144,7 @@ void cmGlobalVisualStudio10Generator
|
|||
::EnableLanguage(std::vector<std::string>const & lang,
|
||||
cmMakefile *mf, bool optional)
|
||||
{
|
||||
if(!strcmp(this->ArchitectureId, "Itanium") ||
|
||||
!strcmp(this->ArchitectureId, "x64"))
|
||||
if(this->ArchitectureId == "Itanium" || this->ArchitectureId == "x64")
|
||||
{
|
||||
if(this->IsExpressEdition() && !this->Find64BitTools(mf))
|
||||
{
|
||||
|
|
|
@ -79,11 +79,11 @@ cmGlobalVisualStudio8Generator::cmGlobalVisualStudio8Generator(
|
|||
//----------------------------------------------------------------------------
|
||||
const char* cmGlobalVisualStudio8Generator::GetPlatformName() const
|
||||
{
|
||||
if (!strcmp(this->ArchitectureId, "X86"))
|
||||
if (this->ArchitectureId == "X86")
|
||||
{
|
||||
return "Win32";
|
||||
}
|
||||
return this->ArchitectureId;
|
||||
return this->ArchitectureId.c_str();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
|
|
|
@ -499,8 +499,8 @@ void cmGlobalVisualStudioGenerator::ComputeVSTargetDepends(cmTarget& target)
|
|||
//----------------------------------------------------------------------------
|
||||
void cmGlobalVisualStudioGenerator::AddPlatformDefinitions(cmMakefile* mf)
|
||||
{
|
||||
mf->AddDefinition("MSVC_C_ARCHITECTURE_ID", this->ArchitectureId);
|
||||
mf->AddDefinition("MSVC_CXX_ARCHITECTURE_ID", this->ArchitectureId);
|
||||
mf->AddDefinition("MSVC_C_ARCHITECTURE_ID", this->ArchitectureId.c_str());
|
||||
mf->AddDefinition("MSVC_CXX_ARCHITECTURE_ID", this->ArchitectureId.c_str());
|
||||
|
||||
if(this->AdditionalPlatformDefinition)
|
||||
{
|
||||
|
|
|
@ -101,7 +101,7 @@ protected:
|
|||
std::string GetUtilityDepend(cmTarget* target);
|
||||
typedef std::map<cmTarget*, cmStdString> UtilityDependsMap;
|
||||
UtilityDependsMap UtilityDepends;
|
||||
const char* ArchitectureId;
|
||||
std::string ArchitectureId;
|
||||
const char* AdditionalPlatformDefinition;
|
||||
|
||||
private:
|
||||
|
|
Loading…
Reference in New Issue