Merge topic 'export-no-custom-target'

7e9f908e export: Reject custom target exports earlier (#15657)
3b09398a Tests: Teach RunCMake.export to enable languages only when needed
This commit is contained in:
Brad King
2015-07-22 11:04:32 -04:00
committed by CMake Topic Stage
10 changed files with 19 additions and 3 deletions

View File

@@ -177,6 +177,12 @@ bool cmExportCommand
this->SetError(e.str());
return false;
}
if (target->GetType() == cmTarget::UTILITY)
{
this->SetError("given custom target \"" + *currentTarget
+ "\" which may not be exported.");
return false;
}
}
else
{