diff options
author | Brad King <brad.king@kitware.com> | 2007-03-07 20:15:46 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2007-03-07 20:15:46 (GMT) |
commit | fc19882e8f85516c4f774083b6d9f57f843fb941 (patch) | |
tree | 0e673dc5a8b7dfe6eedeb01bfe8f2ec123e3d7bb /Source/cmLocalGenerator.h | |
parent | 3bd9d67488b98cb1141b7aaadbffb6550935f2aa (diff) | |
download | CMake-fc19882e8f85516c4f774083b6d9f57f843fb941.zip CMake-fc19882e8f85516c4f774083b6d9f57f843fb941.tar.gz CMake-fc19882e8f85516c4f774083b6d9f57f843fb941.tar.bz2 |
ENH: Moved ConvertToRelativePath from cmGlobalGenerator to cmLocalGenerator. This is in preparation for setting up each local generator to have its own RelativePathTopSource and RelativePathTopBinary based on its ancestor directories.
Diffstat (limited to 'Source/cmLocalGenerator.h')
-rw-r--r-- | Source/cmLocalGenerator.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Source/cmLocalGenerator.h b/Source/cmLocalGenerator.h index 1b8f124..6b4d7dc 100644 --- a/Source/cmLocalGenerator.h +++ b/Source/cmLocalGenerator.h @@ -266,6 +266,18 @@ protected: std::string GetObjectFileNameWithoutTarget(const cmSourceFile& source); std::string& CreateSafeUniqueObjectFileName(const char* sin); + void ConfigureRelativePaths(); + + /** + * Convert the given remote path to a relative path with respect to + * the given local path. The local path must be given in component + * form (see SystemTools::SplitPath) without a trailing slash. The + * remote path must use forward slashes and not already be escaped + * or quoted. + */ + std::string ConvertToRelativePath(const std::vector<std::string>& local, + const char* remote); + cmMakefile *Makefile; cmGlobalGenerator *GlobalGenerator; // members used for relative path function ConvertToMakefilePath @@ -291,6 +303,15 @@ protected: // Hack for ExpandRuleVariable until object-oriented version is // committed. std::string TargetImplib; + + // The top-most directories for relative path conversion. Both the + // source and destination location of a relative path conversion + // must be underneath one of these directories (both under source or + // both under binary) in order for the relative path to be evaluated + // safely by the build tools. + std::string RelativePathTopSource; + std::string RelativePathTopBinary; + bool RelativePathsConfigured; }; #endif |