| 2871 | } |
| 2872 | |
| 2873 | bool cmFindPackageCommand::SearchDirectory(std::string const& dir, |
| 2874 | PackageDescriptionType type) |
| 2875 | { |
| 2876 | assert(!dir.empty() && dir.back() == '/'); |
| 2877 | |
| 2878 | // Check each path suffix on this directory. |
| 2879 | for (std::string const& s : this->SearchPathSuffixes) { |
| 2880 | std::string d = dir; |
| 2881 | if (!s.empty()) { |
| 2882 | d += s; |
| 2883 | d += '/'; |
| 2884 | } |
| 2885 | if (this->CheckDirectory(d, type)) { |
| 2886 | return true; |
| 2887 | } |
| 2888 | } |
| 2889 | return false; |
| 2890 | } |
| 2891 | |
| 2892 | bool cmFindPackageCommand::CheckDirectory(std::string const& dir, |
| 2893 | PackageDescriptionType type) |
no test coverage detected