diff options
Diffstat (limited to 'Source/cmPolicies.cxx')
-rw-r--r-- | Source/cmPolicies.cxx | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/Source/cmPolicies.cxx b/Source/cmPolicies.cxx index 93072f5..693945d 100644 --- a/Source/cmPolicies.cxx +++ b/Source/cmPolicies.cxx @@ -343,6 +343,22 @@ cmPolicies::cmPolicies() CMP0050, "CMP0050", "Disallow add_custom_command SOURCE signatures.", 3,0,0, cmPolicies::WARN); + + this->DefinePolicy( + CMP0051, "CMP0051", + "List TARGET_OBJECTS in SOURCES target property.", + 3,1,0, cmPolicies::WARN); + + this->DefinePolicy( + CMP0052, "CMP0052", + "Reject source and build dirs in installed " + "INTERFACE_INCLUDE_DIRECTORIES.", + 3,1,0, cmPolicies::WARN); + + this->DefinePolicy( + CMP0053, "CMP0053", + "Simplify variable reference and escape sequence evaluation.", + 3,1,0, cmPolicies::WARN); } cmPolicies::~cmPolicies() @@ -488,7 +504,7 @@ bool cmPolicies::GetPolicyDefault(cmMakefile* mf, std::string const& policy, cmPolicies::PolicyStatus* defaultSetting) { std::string defaultVar = "CMAKE_POLICY_DEFAULT_" + policy; - std::string defaultValue = mf->GetSafeDefinition(defaultVar.c_str()); + std::string defaultValue = mf->GetSafeDefinition(defaultVar); if(defaultValue == "NEW") { *defaultSetting = cmPolicies::NEW; @@ -506,7 +522,7 @@ bool cmPolicies::GetPolicyDefault(cmMakefile* mf, std::string const& policy, cmOStringStream e; e << defaultVar << " has value \"" << defaultValue << "\" but must be \"OLD\", \"NEW\", or \"\" (empty)."; - mf->IssueMessage(cmake::FATAL_ERROR, e.str().c_str()); + mf->IssueMessage(cmake::FATAL_ERROR, e.str()); return false; } @@ -651,5 +667,5 @@ cmPolicies::DiagnoseAncientPolicies(std::vector<PolicyID> const& ancient, << "Please either update your CMakeLists.txt files to conform to " << "the new behavior or use an older version of CMake that still " << "supports the old behavior."; - mf->IssueMessage(cmake::FATAL_ERROR, e.str().c_str()); + mf->IssueMessage(cmake::FATAL_ERROR, e.str()); } |