| 56 | } |
| 57 | |
| 58 | std::vector<std::string> prepareFilesPathsForTree( |
| 59 | std::vector<std::string> const& filesPaths, |
| 60 | std::string const& currentSourceDir) |
| 61 | { |
| 62 | std::vector<std::string> prepared; |
| 63 | prepared.reserve(filesPaths.size()); |
| 64 | |
| 65 | for (auto const& filePath : filesPaths) { |
| 66 | std::string fullPath = |
| 67 | cmSystemTools::CollapseFullPath(filePath, currentSourceDir); |
| 68 | // If provided file path is actually not a directory, silently ignore it. |
| 69 | if (cmSystemTools::FileIsDirectory(fullPath)) { |
| 70 | continue; |
| 71 | } |
| 72 | |
| 73 | // Handle directory that doesn't exist yet. |
| 74 | if (!fullPath.empty() && |
| 75 | (fullPath.back() == '/' || fullPath.back() == '\\')) { |
| 76 | continue; |
| 77 | } |
| 78 | |
| 79 | prepared.emplace_back(std::move(fullPath)); |
| 80 | } |
| 81 | |
| 82 | return prepared; |
| 83 | } |
| 84 | |
| 85 | bool addFilesToItsSourceGroups(std::string const& root, |
| 86 | std::set<std::string> const& sgFilesPaths, |
no test coverage detected
searching dependent graphs…