[cmake-commits] martink committed cmAddCustomTargetCommand.cxx 1.32
1.33 cmPolicies.cxx 1.2 1.3 cmPolicies.h 1.2 1.3
cmake-commits at cmake.org
cmake-commits at cmake.org
Sun Mar 2 08:36:20 EST 2008
Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv32267/Source
Modified Files:
cmAddCustomTargetCommand.cxx cmPolicies.cxx cmPolicies.h
Log Message:
COMP: fix compile errors on vs6 and a warning
Index: cmAddCustomTargetCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmAddCustomTargetCommand.cxx,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- cmAddCustomTargetCommand.cxx 1 Mar 2008 20:44:17 -0000 1.32
+++ cmAddCustomTargetCommand.cxx 2 Mar 2008 13:36:18 -0000 1.33
@@ -46,7 +46,6 @@
"this is not allowed according to policy CMP_0001. Run "
"cmake --help-policy CMP_0001 for more information.");
return false;
- break;
case cmPolicies::REQUIRED_IF_USED:
case cmPolicies::REQUIRED_ALWAYS:
this->SetError(
Index: cmPolicies.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmPolicies.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- cmPolicies.h 1 Mar 2008 20:26:15 -0000 1.2
+++ cmPolicies.h 2 Mar 2008 13:36:18 -0000 1.3
@@ -78,7 +78,7 @@
std::string GetRequiredPolicyError(cmPolicies::PolicyID id);
private:
- std::map<cmPolicies::PolicyID,cmPolicy *> Policies;
+ std::map<cmPolicies::PolicyID,cmPolicy *> PolicyMap;
std::map<std::string,cmPolicies::PolicyID> PolicyStringMap;
};
Index: cmPolicies.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmPolicies.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- cmPolicies.cxx 1 Mar 2008 20:26:15 -0000 1.2
+++ cmPolicies.cxx 2 Mar 2008 13:36:18 -0000 1.3
@@ -118,8 +118,8 @@
{
// free the policies
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator i
- = this->Policies.begin();
- for (;i != this->Policies.end(); ++i)
+ = this->PolicyMap.begin();
+ for (;i != this->PolicyMap.end(); ++i)
{
delete i->second;
}
@@ -135,14 +135,14 @@
cmPolicies::PolicyStatus status)
{
// a policy must be unique and can only be defined once
- if (this->Policies.find(iD) != this->Policies.end())
+ if (this->PolicyMap.find(iD) != this->PolicyMap.end())
{
cmSystemTools::Error("Attempt to redefine a CMake policy for policy "
"ID ", this->GetPolicyIDString(iD).c_str());
return;
}
- this->Policies[iD] = new cmPolicy(iD, idString,
+ this->PolicyMap[iD] = new cmPolicy(iD, idString,
shortDescription,
longDescription,
majorVersionIntroduced,
@@ -187,8 +187,8 @@
// now loop over all the policies and set them as appropriate
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator i
- = this->Policies.begin();
- for (;i != this->Policies.end(); ++i)
+ = this->PolicyMap.begin();
+ for (;i != this->PolicyMap.end(); ++i)
{
if (i->second->IsPolicyNewerThan(majorVer,minorVer,patchVer))
{
@@ -214,7 +214,7 @@
{
// if they are setting a feature to anything other than OLD or WARN and the
// feature is not known about then that is an error
- if (this->Policies.find(id) == this->Policies.end())
+ if (this->PolicyMap.find(id) == this->PolicyMap.end())
{
if (status == cmPolicies::WARN ||
status == cmPolicies::OLD)
@@ -235,7 +235,7 @@
// setting it to WARN or OLD when the feature is REQUIRED_ALWAYS
if ((status == cmPolicies::WARN ||
status == cmPolicies::OLD) &&
- this->Policies[id]->Status == cmPolicies::REQUIRED_ALWAYS)
+ this->PolicyMap[id]->Status == cmPolicies::REQUIRED_ALWAYS)
{
cmOStringStream error;
error <<
@@ -244,7 +244,7 @@
"question is feature " <<
id <<
" which had new behavior introduced in CMake version " <<
- this->Policies[id]->GetVersionString() <<
+ this->PolicyMap[id]->GetVersionString() <<
" please either update your CMakeLists files to conform to " <<
"the new behavior " <<
"or use an older version of CMake that still supports " <<
@@ -263,7 +263,7 @@
{
// if they are setting a feature to anything other than OLD or WARN and the
// feature is not known about then that is an error
- if (this->Policies.find(id) == this->Policies.end())
+ if (this->PolicyMap.find(id) == this->PolicyMap.end())
{
if (status == cmPolicies::WARN ||
status == cmPolicies::OLD)
@@ -284,8 +284,8 @@
// setting it to WARN or OLD when the feature is REQUIRED_ALWAYS
if ((status == cmPolicies::WARN ||
status == cmPolicies::OLD) &&
- (this->Policies[id]->Status == cmPolicies::REQUIRED_ALWAYS ||
- this->Policies[id]->Status == cmPolicies::REQUIRED_IF_USED))
+ (this->PolicyMap[id]->Status == cmPolicies::REQUIRED_ALWAYS ||
+ this->PolicyMap[id]->Status == cmPolicies::REQUIRED_IF_USED))
{
cmOStringStream error;
error <<
@@ -294,7 +294,7 @@
"question is feature " <<
id <<
" which had new behavior introduced in CMake version " <<
- this->Policies[id]->GetVersionString() <<
+ this->PolicyMap[id]->GetVersionString() <<
" please either update your CMakeLists files to conform to " <<
"the new behavior " <<
"or use an older version of CMake that still supports " <<
@@ -326,8 +326,8 @@
std::string cmPolicies::GetPolicyIDString(cmPolicies::PolicyID pid)
{
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator pos =
- this->Policies.find(pid);
- if (pos == this->Policies.end())
+ this->PolicyMap.find(pid);
+ if (pos == this->PolicyMap.end())
{
return "";
}
@@ -339,8 +339,8 @@
std::string cmPolicies::GetPolicyWarning(cmPolicies::PolicyID id)
{
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator pos =
- this->Policies.find(id);
- if (pos == this->Policies.end())
+ this->PolicyMap.find(id);
+ if (pos == this->PolicyMap.end())
{
cmSystemTools::Error(
"Request for warning text for undefined policy!");
@@ -367,8 +367,8 @@
std::string cmPolicies::GetRequiredPolicyError(cmPolicies::PolicyID id)
{
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator pos =
- this->Policies.find(id);
- if (pos == this->Policies.end())
+ this->PolicyMap.find(id);
+ if (pos == this->PolicyMap.end())
{
cmSystemTools::Error(
"Request for error text for undefined policy!");
@@ -399,8 +399,8 @@
{
// if the policy is not know then what?
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator pos =
- this->Policies.find(id);
- if (pos == this->Policies.end())
+ this->PolicyMap.find(id);
+ if (pos == this->PolicyMap.end())
{
// TODO is this right?
return cmPolicies::WARN;
More information about the Cmake-commits
mailing list