diff options
author | Brad King <brad.king@kitware.com> | 2021-05-13 13:47:33 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2021-05-13 16:48:43 (GMT) |
commit | f6d4fa63f84a88dbc59020b10fbdb7fb02fa1f9d (patch) | |
tree | 53305a4e22f31f881dec3b5c6784a35103e47e13 /Source/cmStateDirectory.cxx | |
parent | f0ffb1e2d4431c705a37410890f38de5f3cf5526 (diff) | |
download | CMake-f6d4fa63f84a88dbc59020b10fbdb7fb02fa1f9d.zip CMake-f6d4fa63f84a88dbc59020b10fbdb7fb02fa1f9d.tar.gz CMake-f6d4fa63f84a88dbc59020b10fbdb7fb02fa1f9d.tar.bz2 |
cmStateDirectory: Comment relative path top directory selection approach
Diffstat (limited to 'Source/cmStateDirectory.cxx')
-rw-r--r-- | Source/cmStateDirectory.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmStateDirectory.cxx b/Source/cmStateDirectory.cxx index 7f25b4b..a0bfd28 100644 --- a/Source/cmStateDirectory.cxx +++ b/Source/cmStateDirectory.cxx @@ -44,6 +44,9 @@ void cmStateDirectory::ComputeRelativePathTopSource() std::string result = snapshots.front().GetDirectory().GetCurrentSource(); + // Walk up the buildsystem directory tree to find the highest source + // directory that contains the current source directory and the + // intermediate ancestors. for (cmStateSnapshot const& snp : cmMakeRange(snapshots).advance(1)) { std::string currentSource = snp.GetDirectory().GetCurrentSource(); if (cmSystemTools::IsSubDirectory(result, currentSource)) { @@ -69,6 +72,9 @@ void cmStateDirectory::ComputeRelativePathTopBinary() std::string result = snapshots.front().GetDirectory().GetCurrentBinary(); + // Walk up the buildsystem directory tree to find the highest binary + // directory that contains the current binary directory and the + // intermediate ancestors. for (cmStateSnapshot const& snp : cmMakeRange(snapshots).advance(1)) { std::string currentBinary = snp.GetDirectory().GetCurrentBinary(); if (cmSystemTools::IsSubDirectory(result, currentBinary)) { |