mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-07 22:59:56 -05:00
cmake: avoid getcwd in CollapseFullPath
`CollapseFullPath` calls getcwd, which is a rather expensive system call. we can replace it with `GetHomeOutputDirectory()` to save us from the calling overhead
This commit is contained in:
@@ -3087,7 +3087,8 @@ std::vector<BT<std::string>> cmGeneratorTarget::GetIncludeDirectories(
|
||||
cmLinkImplementationLibraries const* impl =
|
||||
this->GetLinkImplementationLibraries(config);
|
||||
for (cmLinkImplItem const& lib : impl->Libraries) {
|
||||
std::string libDir = cmSystemTools::CollapseFullPath(lib.AsStr());
|
||||
std::string libDir = cmSystemTools::CollapseFullPath(
|
||||
lib.AsStr(), this->Makefile->GetHomeOutputDirectory());
|
||||
|
||||
static cmsys::RegularExpression frameworkCheck(
|
||||
"(.*\\.framework)(/Versions/[^/]+)?/[^/]+$");
|
||||
|
||||
Reference in New Issue
Block a user