ENH: Added computation of object file names that are almost always short enough to not exceed the filesystem path length limitation. This is useful when a source file from outside the tree is referenced with a long full path. The object file name previously would contain the entire path which when combined with the build output directory could exceed the filesystem limit. Now CMake recognizes this case and replaces enough of the beginning of the full path to the source file with an md5sum of the replaced portion to make the name fit on disk. This addresses bug#4520.

This commit is contained in:
Brad King
2007-03-16 10:34:25 -04:00
parent 77da3d9b79
commit 1f639ee76c
8 changed files with 199 additions and 25 deletions
+4 -2
View File
@@ -266,8 +266,10 @@ protected:
std::vector<std::string> const& configurationTypes);
// Compute object file names.
std::string GetObjectFileNameWithoutTarget(const cmSourceFile& source);
std::string& CreateSafeUniqueObjectFileName(const char* sin);
std::string GetObjectFileNameWithoutTarget(const cmSourceFile& source,
std::string::size_type dir_len);
std::string& CreateSafeUniqueObjectFileName(const char* sin,
std::string::size_type dir_len);
void ConfigureRelativePaths();
std::string FindRelativePathTopSource();