diff options
| author | Robert Maynard <rmaynard@nvidia.com> | 2022-07-20 17:03:50 -0400 |
|---|---|---|
| committer | Brad King <brad.king@kitware.com> | 2022-07-22 13:55:52 -0400 |
| commit | 846a650ff7f4aa609a95d57b01b065a1d4bd7101 (patch) | |
| tree | 289ac58fdd3178f5c59da18b1d656ab08ba32894 /Source/cmake.cxx | |
| parent | c362cba566a4db39f3c682b06f680a09544f16a2 (diff) | |
| download | cmake-846a650ff7f4aa609a95d57b01b065a1d4bd7101.tar.gz | |
cmake: In -P mode ignore extra paths on the command line
Fixes: #23748
Diffstat (limited to 'Source/cmake.cxx')
| -rw-r--r-- | Source/cmake.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx index 4e1862854c..1c1cab37fd 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -1796,7 +1796,8 @@ void cmake::SetHomeDirectoryViaCommandLine(std::string const& path) } auto prev_path = this->GetHomeDirectory(); - if (prev_path != path && !prev_path.empty()) { + if (prev_path != path && !prev_path.empty() && + this->GetWorkingMode() == NORMAL_MODE) { this->IssueMessage(MessageType::WARNING, cmStrCat("Ignoring extra path from command line:\n \"", prev_path, "\"")); |
