BUG: Fix include_directories command to produce an immediately whether or not 2.4 compatibility is enabled. CMake 2.4 already produced an error, just not immediately.
This commit is contained in:
parent
959bd61e37
commit
bf732ec464
|
@ -50,17 +50,8 @@ bool cmIncludeDirectoryCommand
|
||||||
}
|
}
|
||||||
if(i->size() == 0)
|
if(i->size() == 0)
|
||||||
{
|
{
|
||||||
const char* errorMessage
|
this->SetError("given empty-string as include directory.");
|
||||||
= "Empty Include Directory Passed into INCLUDE_DIRECTORIES command.";
|
return false;
|
||||||
if(this->Makefile->NeedBackwardsCompatibility(2,4))
|
|
||||||
{
|
|
||||||
cmSystemTools::Error(errorMessage);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
this->SetError(errorMessage);
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this->AddDirectory(i->c_str(),before,system);
|
this->AddDirectory(i->c_str(),before,system);
|
||||||
|
|
Loading…
Reference in New Issue