ENH: configure file will assume start source dir if a full path is not provided

This commit is contained in:
Ken Martin 2005-07-07 16:01:35 -04:00
parent 13e99490fb
commit f3ed62b75a
1 changed files with 8 additions and 1 deletions

View File

@ -88,7 +88,14 @@ void cmConfigureFileCommand::FinalPass()
int cmConfigureFileCommand::ConfigureFile()
{
return m_Makefile->ConfigureFile(m_InputFile.c_str(),
std::string inFile = m_InputFile;
if (!cmSystemTools::FileIsFullPath(inFile.c_str()))
{
inFile = m_Makefile->GetStartDirectory();
inFile += "/";
inFile += m_InputFile;
}
return m_Makefile->ConfigureFile(inFile.c_str(),
m_OuputFile.c_str(),
m_CopyOnly,
m_AtOnly,