FPHSA: Fix regression when VERSION_VAR is missing

If a package is found but FPHSA is called by the find module without a VERSION_VAR, and the find_package call specifies a version, we have previously accepted the package as found. This was accidentally regressed by !7527 (merged). Restore it and add a test case.

Merge request reports

Loading