summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/SystemTools.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2007-02-22 20:27:56 (GMT)
committerBrad King <brad.king@kitware.com>2007-02-22 20:27:56 (GMT)
commit2a64bb477462a03da3ba917364d9e66921665bc9 (patch)
tree49d116d591b7af893ac189332e4955992800e744 /Source/kwsys/SystemTools.cxx
parent8529efdd878bc838fb7463bf4cd83947a5775375 (diff)
downloadCMake-2a64bb477462a03da3ba917364d9e66921665bc9.zip
CMake-2a64bb477462a03da3ba917364d9e66921665bc9.tar.gz
CMake-2a64bb477462a03da3ba917364d9e66921665bc9.tar.bz2
BUG: Fix bug#4482.
Diffstat (limited to 'Source/kwsys/SystemTools.cxx')
-rw-r--r--Source/kwsys/SystemTools.cxx13
1 files changed, 12 insertions, 1 deletions
diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx
index 4de9e15..3b12216 100644
--- a/Source/kwsys/SystemTools.cxx
+++ b/Source/kwsys/SystemTools.cxx
@@ -2693,13 +2693,24 @@ kwsys_stl::string SystemTools::RelativePath(const char* local, const char* remot
remoteSplit[sameCount] = "";
sameCount++;
}
+
+#if 0
+ // NOTE: We did this at one time to prevent relative paths to the
+ // compiler from looking like "../../../../../../../usr/bin/gcc".
+ // Now however relative paths are only computed for destinations
+ // inside the build tree so this is not a problem. This is now a
+ // general-purpose method and should not have this hack. I'm
+ // leaving it in place in case removing it causes a problem so it is
+ // easy to restore:
+ //
// If there is nothing in common but the root directory, then just
// return the full path.
if(sameCount <= 1)
{
return remote;
}
-
+#endif
+
// for each entry that is not common in the local path
// add a ../ to the finalpath array, this gets us out of the local
// path into the remote dir