expand vars nwo for exists test

This commit is contained in:
Ken Martin 2002-01-03 09:34:40 -05:00
parent e07ea14e31
commit d163cb7014
2 changed files with 6 additions and 2 deletions

View File

@ -75,7 +75,9 @@ bool cmElseCommand::InitialPass(std::vector<std::string> const& args)
if (args.size() == 2 && (args[0] == "EXISTS"))
{
if(cmSystemTools::FileExists(args[1].c_str()))
std::string tmp = args[1];
m_Makefile->ExpandVariablesInString(tmp);
if(cmSystemTools::FileExists(tmp.c_str()))
{
f = new cmIfFunctionBlocker();
}

View File

@ -136,7 +136,9 @@ bool cmIfCommand::InitialPass(std::vector<std::string> const& args)
if (args.size() == 2 && (args[0] == "EXISTS"))
{
if(!cmSystemTools::FileExists(args[1].c_str()))
std::string tmp = args[1];
m_Makefile->ExpandVariablesInString(tmp);
if(!cmSystemTools::FileExists(tmp.c_str()))
{
f = new cmIfFunctionBlocker();
}