summaryrefslogtreecommitdiffstats
path: root/Source/cmSystemTools.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2003-11-26 19:52:12 (GMT)
committerBrad King <brad.king@kitware.com>2003-11-26 19:52:12 (GMT)
commit9a58ac6649a9e12e06306a7d23aaaf767dea0e64 (patch)
tree556502e90100c748f4874f06d2f0e2f0e606f32e /Source/cmSystemTools.cxx
parent725de95b7e5b2bd6c43b8dc576a0e4d256fbcb4a (diff)
downloadCMake-9a58ac6649a9e12e06306a7d23aaaf767dea0e64.zip
CMake-9a58ac6649a9e12e06306a7d23aaaf767dea0e64.tar.gz
CMake-9a58ac6649a9e12e06306a7d23aaaf767dea0e64.tar.bz2
ENH: Added CreateSymlink method.
Diffstat (limited to 'Source/cmSystemTools.cxx')
-rw-r--r--Source/cmSystemTools.cxx10
1 files changed, 10 insertions, 0 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx
index 1d12ac9..50a43ef 100644
--- a/Source/cmSystemTools.cxx
+++ b/Source/cmSystemTools.cxx
@@ -1060,3 +1060,13 @@ bool cmSystemTools::StringEndsWith(const char* str1, const char* str2)
}
return !strncmp(str1 + (strlen(str1)-strlen(str2)), str2, strlen(str2));
}
+
+bool cmSystemTools::CreateSymlink(const char* origName, const char* newName)
+{
+#if !defined(_WIN32) || defined(__CYGWIN__)
+ return (symlink(origName, newName) >= 0);
+#else
+ // Should we create a copy here?
+ return false;
+#endif
+}