| 23 | } |
| 24 | |
| 25 | void cmBinUtilsLinker::NormalizePath(std::string& path) const |
| 26 | { |
| 27 | std::string normalizedPath = |
| 28 | cmCMakePath(path, cmCMakePath::auto_format).GenericString(); |
| 29 | |
| 30 | if (path == normalizedPath) { |
| 31 | return; |
| 32 | } |
| 33 | |
| 34 | cmPolicies::PolicyStatus policy = |
| 35 | this->Archive->GetMakefile()->GetPolicyStatus(cmPolicies::CMP0207); |
| 36 | if (policy == cmPolicies::WARN) { |
| 37 | this->Archive->GetMakefile()->IssueMessage( |
| 38 | MessageType::AUTHOR_WARNING, |
| 39 | cmStrCat(cmPolicies::GetPolicyWarning(cmPolicies::CMP0207), |
| 40 | "\n" |
| 41 | "Path\n \"", |
| 42 | path, |
| 43 | "\"\n" |
| 44 | "would be converted to\n \"", |
| 45 | normalizedPath, "\"\n")); |
| 46 | } else if (policy == cmPolicies::NEW) { |
| 47 | path = std::move(normalizedPath); |
| 48 | } |
| 49 | } |
no test coverage detected