diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 3ceeb2ecd..289bf90c9 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -1324,6 +1324,11 @@ void cmGlobalGenerator::CreateDefaultGlobalTargets(cmTargets* targets) // We are building CMake itself. We cannot use the original // executable to install over itself. cmd = mf->GetDefinition("EXECUTABLE_OUTPUT_PATH"); + if(cmakeCfgIntDir && *cmakeCfgIntDir && cmakeCfgIntDir[0] != '.') + { + cmd += "/"; + cmd += cmakeCfgIntDir; + } cmd += "/cmake"; } else