ENH: Warn and ignore EXACT without version
If the find_package command is invoked with the EXACT option but without a version, warn and ignore the option.
This commit is contained in:
parent
7f819903ed
commit
75f8d5aab7
|
@ -468,6 +468,14 @@ bool cmFindPackageCommand
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Ignore EXACT with no version.
|
||||||
|
if(this->Version.empty() && this->VersionExact)
|
||||||
|
{
|
||||||
|
this->VersionExact = false;
|
||||||
|
this->Makefile->IssueMessage(
|
||||||
|
cmake::AUTHOR_WARNING, "Ignoring EXACT since no version is requested.");
|
||||||
|
}
|
||||||
|
|
||||||
if(!this->Version.empty())
|
if(!this->Version.empty())
|
||||||
{
|
{
|
||||||
// Try to parse the version number and store the results that were
|
// Try to parse the version number and store the results that were
|
||||||
|
|
Loading…
Reference in New Issue