mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-06 14:19:59 -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:
@@ -215,7 +215,8 @@ bool cmAddCustomCommandCommand(std::vector<std::string> const& args,
|
||||
}
|
||||
|
||||
if (cmSystemTools::FileIsFullPath(filename)) {
|
||||
filename = cmSystemTools::CollapseFullPath(filename);
|
||||
filename = cmSystemTools::CollapseFullPath(
|
||||
filename, status.GetMakefile().GetHomeOutputDirectory());
|
||||
}
|
||||
switch (doing) {
|
||||
case doing_depfile:
|
||||
|
||||
Reference in New Issue
Block a user