summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmGlobalUnixMakefileGenerator3.cxx12
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx6
-rw-r--r--Source/cmLocalGenerator.cxx24
-rw-r--r--Source/cmLocalGenerator.h21
-rw-r--r--Source/cmLocalVisualStudio6Generator.cxx5
-rw-r--r--Source/cmLocalVisualStudio7Generator.cxx5
6 files changed, 18 insertions, 55 deletions
diff --git a/Source/cmGlobalUnixMakefileGenerator3.cxx b/Source/cmGlobalUnixMakefileGenerator3.cxx
index c225f43..8c3c997 100644
--- a/Source/cmGlobalUnixMakefileGenerator3.cxx
+++ b/Source/cmGlobalUnixMakefileGenerator3.cxx
@@ -290,12 +290,14 @@ void cmGlobalUnixMakefileGenerator3::WriteMainCMakefile()
cmakefileStream
<< "# The top level Makefile was generated from the following files:\n"
<< "SET(CMAKE_MAKEFILE_DEPENDS\n"
- << " \"" << lg->ConvertToRelativePath(cache.c_str()).c_str() << "\"\n";
+ << " \"" << lg->Convert(cache.c_str(),
+ cmLocalGenerator::START_OUTPUT).c_str() << "\"\n";
for(std::vector<std::string>::const_iterator i = lfiles.begin();
i != lfiles.end(); ++i)
{
cmakefileStream
- << " \"" << lg->ConvertToRelativePath(i->c_str()).c_str()
+ << " \"" << lg->Convert(i->c_str(),
+ cmLocalGenerator::START_OUTPUT).c_str()
<< "\"\n";
}
cmakefileStream
@@ -309,8 +311,10 @@ void cmGlobalUnixMakefileGenerator3::WriteMainCMakefile()
cmakefileStream
<< "# The corresponding makefile is:\n"
<< "SET(CMAKE_MAKEFILE_OUTPUTS\n"
- << " \"" << lg->ConvertToRelativePath(makefileName.c_str()).c_str() << "\"\n"
- << " \"" << lg->ConvertToRelativePath(check.c_str()).c_str() << "\"\n";
+ << " \"" << lg->Convert(makefileName.c_str(),
+ cmLocalGenerator::START_OUTPUT).c_str() << "\"\n"
+ << " \"" << lg->Convert(check.c_str(),
+ cmLocalGenerator::START_OUTPUT).c_str() << "\"\n";
// add in all the directory information files
std::string tmpStr;
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index 6a1f941..259d8a3 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -1634,7 +1634,8 @@ std::string cmGlobalXCodeGenerator::ConvertToRelativeForMake(const char* p)
}
else
{
- std::string ret = this->ConvertToRelativePath(m_CurrentOutputDirectoryComponents, p);
+ std::string ret =
+ this->ConvertToRelativePath(m_CurrentOutputDirectoryComponents, p);
return cmSystemTools::ConvertToOutputPath(ret.c_str());
}
}
@@ -1648,7 +1649,8 @@ std::string cmGlobalXCodeGenerator::ConvertToRelativeForXCode(const char* p)
}
else
{
- std::string ret = this->ConvertToRelativePath(m_ProjectOutputDirectoryComponents, p);
+ std::string ret =
+ this->ConvertToRelativePath(m_ProjectOutputDirectoryComponents, p);
return cmSystemTools::ConvertToOutputPath(ret.c_str());
}
}
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index a76fc2a..b8267d6 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -481,7 +481,6 @@ void cmLocalGenerator::AddCustomCommandToCreateObject(const char* ofname,
cmSourceFile& source,
cmTarget& )
{
- // std::string objectFile = this->ConvertToRelativeOutputPath(ofname);
std::string objectFile = this->Convert(ofname,START_OUTPUT,SHELL);
std::string sourceFile =
this->Convert(source.GetFullPath().c_str(),START_OUTPUT,SHELL,true);
@@ -1440,29 +1439,6 @@ cmLocalGenerator::ConstructScript(const cmCustomCommandLines& commandLines,
}
//----------------------------------------------------------------------------
-std::string cmLocalGenerator::ConvertToRelativePath(const char* remote)
-{
- return this->Convert(remote,START_OUTPUT);
-}
-
-//----------------------------------------------------------------------------
-std::string
-cmLocalGenerator::ConvertToRelativeOutputPath(const char* remote)
-{
- // TODO: Make this behave like its documentation...always convert.
- // This involves identifying all calls to it that should be calls to
- // the optional one.
- return this->ConvertToOptionallyRelativeOutputPath(remote);
-}
-
-//----------------------------------------------------------------------------
-std::string
-cmLocalGenerator::ConvertToOptionallyRelativePath(const char* remote)
-{
- return this->Convert(remote, START_OUTPUT, UNCHANGED, true);
-}
-
-//----------------------------------------------------------------------------
std::string
cmLocalGenerator::ConvertToOptionallyRelativeOutputPath(const char* remote)
{
diff --git a/Source/cmLocalGenerator.h b/Source/cmLocalGenerator.h
index 036b3d2..c1177d8 100644
--- a/Source/cmLocalGenerator.h
+++ b/Source/cmLocalGenerator.h
@@ -98,27 +98,6 @@ public:
bool optional = false);
/**
- * Convert the given remote path to a relative path with respect to
- * this generator's output directory. The remote path must use
- * forward slashes and not already be escaped or quoted.
- */
- std::string ConvertToRelativePath(const char* remote);
-
- /**
- * Convert to an output path that is relative to the current output
- * directory. The remote path must use forward slashes and not
- * already be escaped or quoted.
- */
- std::string ConvertToRelativeOutputPath(const char* remote);
-
- /**
- * Calls ConvertToRelativePath conditionally on the cache option
- * CMAKE_USE_RELATIVE_PATHS. The remote path must use forward
- * slashes and not already be escaped or quoted.
- */
- std::string ConvertToOptionallyRelativePath(const char* remote);
-
- /**
* Convert the given path to an output path that is optionally
* relative based on the cache option CMAKE_USE_RELATIVE_PATHS. The
* remote path must use forward slashes and not already be escaped
diff --git a/Source/cmLocalVisualStudio6Generator.cxx b/Source/cmLocalVisualStudio6Generator.cxx
index ae19cc7..f463717 100644
--- a/Source/cmLocalVisualStudio6Generator.cxx
+++ b/Source/cmLocalVisualStudio6Generator.cxx
@@ -172,11 +172,12 @@ void cmLocalVisualStudio6Generator::AddDSPBuildRule()
std::string args;
args = "-H";
args +=
- this->ConvertToRelativeOutputPath(m_Makefile->GetHomeDirectory());
+ this->Convert(m_Makefile->GetHomeDirectory(),START_OUTPUT, SHELL, true);
commandLine.push_back(args);
args = "-B";
args +=
- this->ConvertToRelativeOutputPath(m_Makefile->GetHomeOutputDirectory());
+ this->Convert(m_Makefile->GetHomeOutputDirectory(),
+ START_OUTPUT, SHELL, true);
commandLine.push_back(args);
std::string configFile =
diff --git a/Source/cmLocalVisualStudio7Generator.cxx b/Source/cmLocalVisualStudio7Generator.cxx
index f92bbb0..649c6e0 100644
--- a/Source/cmLocalVisualStudio7Generator.cxx
+++ b/Source/cmLocalVisualStudio7Generator.cxx
@@ -147,11 +147,12 @@ void cmLocalVisualStudio7Generator::AddVCProjBuildRule()
std::string args;
args = "-H";
args +=
- this->ConvertToRelativeOutputPath(m_Makefile->GetHomeDirectory());
+ this->Convert(m_Makefile->GetHomeDirectory(), START_OUTPUT, SHELL, true);
commandLine.push_back(args);
args = "-B";
args +=
- this->ConvertToRelativeOutputPath(m_Makefile->GetHomeOutputDirectory());
+ this->Convert(m_Makefile->GetHomeOutputDirectory(),
+ START_OUTPUT, SHELL, true);
commandLine.push_back(args);
std::string configFile =