Factor cmLocalGenerator::Configure object max path

Much of the code in this method was dedicated to computing ObjectMaxPath
after configuring the directory.  We move this last step into its own
ComputeObjectMaxPath method for better organization.
This commit is contained in:
Brad King 2009-09-03 08:26:46 -04:00
parent a6890a1673
commit 1db5c90644
2 changed files with 9 additions and 4 deletions

View File

@ -121,8 +121,15 @@ void cmLocalGenerator::Configure()
// relative paths.
this->UseRelativePaths = this->Makefile->IsOn("CMAKE_USE_RELATIVE_PATHS");
// Choose a maximum object file name length.
this->ComputeObjectMaxPath();
this->Configured = true;
}
//----------------------------------------------------------------------------
void cmLocalGenerator::ComputeObjectMaxPath()
{
// Choose a maximum object file name length.
#if defined(_WIN32) || defined(__CYGWIN__)
this->ObjectPathMax = 250;
#else
@ -159,9 +166,6 @@ void cmLocalGenerator::Configure()
this->ObjectMaxPathViolations.clear();
}
this->Configured = true;
}
void cmLocalGenerator::SetupPathConversions()
{
// Setup the current output directory components for use by

View File

@ -352,6 +352,7 @@ protected:
std::string& CreateSafeUniqueObjectFileName(const char* sin,
std::string const& dir_max);
void ComputeObjectMaxPath();
void ConfigureRelativePaths();
std::string FindRelativePathTopSource();