Remove old check for duplicate subdirectories
In cmMakefile::AddSubDirectory we were checking for addition of the same source directory multiple times. However, the check code was incorrect because it compared pointers instetad of pointed-to strings. Since the check was written, a better check was added right after it to enforce unique binary directories (in which case duplicate sources are fine). This commit simply removes the old-style check code.
This commit is contained in:
parent
ab64fba44f
commit
ef8434284f
@ -1539,21 +1539,6 @@ void cmMakefile::AddSubDirectory(const char* srcPath, const char *binPath,
|
|||||||
bool excludeFromAll, bool preorder,
|
bool excludeFromAll, bool preorder,
|
||||||
bool immediate)
|
bool immediate)
|
||||||
{
|
{
|
||||||
std::vector<cmLocalGenerator *>& children =
|
|
||||||
this->LocalGenerator->GetChildren();
|
|
||||||
// has this directory already been added? If so error
|
|
||||||
unsigned int i;
|
|
||||||
for (i = 0; i < children.size(); ++i)
|
|
||||||
{
|
|
||||||
if (srcPath == children[i]->GetMakefile()->GetStartDirectory())
|
|
||||||
{
|
|
||||||
cmSystemTools::Error
|
|
||||||
("Attempt to add subdirectory multiple times for directory.\n",
|
|
||||||
srcPath);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Make sure the binary directory is unique.
|
// Make sure the binary directory is unique.
|
||||||
if(!this->EnforceUniqueDir(srcPath, binPath))
|
if(!this->EnforceUniqueDir(srcPath, binPath))
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user