mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-23 06:47:08 -05:00
Merge topic 'restore-cwd-translation-map' into release-3.18
85a945a607 Restore handling of build directory inside a symlinked path
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4963
This commit is contained in:
@@ -312,7 +312,7 @@ int main(int argc, char const* const* argv)
|
||||
// The value has not been set on the command line
|
||||
else {
|
||||
// get a default value (current working directory)
|
||||
cpackProjectDirectory = cmsys::SystemTools::GetCurrentWorkingDirectory();
|
||||
cpackProjectDirectory = cmSystemTools::GetCurrentWorkingDirectory();
|
||||
// use default value if no value has been provided by the config file
|
||||
if (!globalMF.IsSet("CPACK_PACKAGE_DIRECTORY")) {
|
||||
globalMF.AddDefinition("CPACK_PACKAGE_DIRECTORY",
|
||||
|
||||
@@ -2082,6 +2082,12 @@ std::string const& cmSystemTools::GetCMakeRoot()
|
||||
return cmSystemToolsCMakeRoot;
|
||||
}
|
||||
|
||||
std::string cmSystemTools::GetCurrentWorkingDirectory()
|
||||
{
|
||||
return cmSystemTools::CollapseFullPath(
|
||||
cmsys::SystemTools::GetCurrentWorkingDirectory());
|
||||
}
|
||||
|
||||
void cmSystemTools::MakefileColorEcho(int color, const char* message,
|
||||
bool newline, bool enabled)
|
||||
{
|
||||
|
||||
@@ -390,6 +390,9 @@ public:
|
||||
static std::string const& GetCMClDepsCommand();
|
||||
static std::string const& GetCMakeRoot();
|
||||
|
||||
/** Get the CWD mapped through the KWSys translation map. */
|
||||
static std::string GetCurrentWorkingDirectory();
|
||||
|
||||
/** Echo a message in color using KWSys's Terminal cprintf. */
|
||||
static void MakefileColorEcho(int color, const char* message, bool newLine,
|
||||
bool enabled);
|
||||
|
||||
Reference in New Issue
Block a user