diff options
author | Ken Martin <ken.martin@kitware.com> | 2004-10-04 16:31:09 (GMT) |
---|---|---|
committer | Ken Martin <ken.martin@kitware.com> | 2004-10-04 16:31:09 (GMT) |
commit | 1066af45278f29e7a5f1b5ba3d7d12bce15719e4 (patch) | |
tree | 6beeea084d3bb262b2d9ada6c562a4ac7109e34c /Source/kwsys/SystemTools.hxx.in | |
parent | 7e3c70082ae433e7793afad6d9a3366bf6c1e215 (diff) | |
download | CMake-1066af45278f29e7a5f1b5ba3d7d12bce15719e4.zip CMake-1066af45278f29e7a5f1b5ba3d7d12bce15719e4.tar.gz CMake-1066af45278f29e7a5f1b5ba3d7d12bce15719e4.tar.bz2 |
ENH: Mathieus support for path conversions
Diffstat (limited to 'Source/kwsys/SystemTools.hxx.in')
-rw-r--r-- | Source/kwsys/SystemTools.hxx.in | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/Source/kwsys/SystemTools.hxx.in b/Source/kwsys/SystemTools.hxx.in index 1c48af7..128e0c2 100644 --- a/Source/kwsys/SystemTools.hxx.in +++ b/Source/kwsys/SystemTools.hxx.in @@ -17,6 +17,7 @@ #include <@KWSYS_NAMESPACE@/ios/iosfwd> #include <@KWSYS_NAMESPACE@/stl/string> #include <@KWSYS_NAMESPACE@/stl/vector> +#include <@KWSYS_NAMESPACE@/stl/map> #include <@KWSYS_NAMESPACE@/Configure.h> @@ -291,6 +292,22 @@ public: static int GetTerminalWidth(); /** + * Add an entry in the path translation table. + */ + static void AddTranslationPath(const char * dir, const char * refdir); + + /** + * If dir is different after CollapseFullPath is called, + * Then insert it into the path translation table + */ + static void AddKeepPath(const char* dir); + + /** + * Update path by going through the Path Translation table; + */ + static void CheckTranslationPath(kwsys_stl::string & path); + + /** * Get and set permissions of the file. */ static bool GetPermissions(const char* file, mode_t& mode); @@ -312,6 +329,12 @@ protected: */ static kwsys_stl::string ConvertToWindowsOutputPath(const char*); +private: + /** + * Path translation table from dir to refdir + * Each time 'dir' will be found it will be replace by 'refdir' + */ + static kwsys_stl::map<kwsys_stl::string,kwsys_stl::string> TranslationMap; }; } // namespace @KWSYS_NAMESPACE@ |