fix to executable depends for custom commands

This commit is contained in:
Ken Martin 2003-08-28 16:06:06 -04:00
parent 62fec9b386
commit 2b2a9d73da
2 changed files with 24 additions and 4 deletions

View File

@ -465,10 +465,20 @@ void cmLocalVisualStudio6Generator::WriteCustomRule(std::ostream& fout,
}
std::string libPath = dep + "_CMAKE_PATH";
const char* cacheValue = m_Makefile->GetDefinition(libPath.c_str());
if (!cacheValue)
if (cacheValue)
{
fout << "\\\n\t" <<
cmSystemTools::ConvertToOutputPath(d->c_str());
libPath = cacheValue;
libPath += "/";
libPath += "$(INTDIR)";
libPath += dep;
libPath += ".exe";
fout << cmSystemTools::ConvertToOutputPath(libPath.c_str())
<< ";";
}
else
{
fout << cmSystemTools::ConvertToOutputPath(d->c_str())
<< ";";
}
}
fout << "\n";

View File

@ -869,7 +869,17 @@ WriteCustomRule(std::ostream& fout,
}
std::string libPath = dep + "_CMAKE_PATH";
const char* cacheValue = m_Makefile->GetDefinition(libPath.c_str());
if (!cacheValue)
if (cacheValue)
{
libPath = cacheValue;
libPath += "/";
libPath += "$(INTDIR)";
libPath += dep;
libPath += ".exe";
fout << this->ConvertToXMLOutputPath(libPath.c_str())
<< ";";
}
else
{
fout << this->ConvertToXMLOutputPath(d->c_str())
<< ";";