|
|
@@ -2524,6 +2524,16 @@ bool cmFindPackageCommand::SearchPrefix(std::string const& prefix_in)
|
|
|
return true;
|
|
|
}
|
|
|
|
|
|
+ auto secondPkgDirGen =
|
|
|
+ cmProjectDirectoryListGenerator{ this->Names, this->SortOrder,
|
|
|
+ this->SortDirection };
|
|
|
+
|
|
|
+ // PREFIX/(Foo|foo|FOO).*/(cmake|CMake)/(Foo|foo|FOO).*/
|
|
|
+ if (TryGeneratedPaths(searchFn, prefix, firstPkgDirGen, iCMakeGen,
|
|
|
+ secondPkgDirGen)) {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+
|
|
|
// Construct list of common install locations (lib and share).
|
|
|
std::vector<cm::string_view> common;
|
|
|
std::string libArch;
|
|
|
@@ -2561,10 +2571,6 @@ bool cmFindPackageCommand::SearchPrefix(std::string const& prefix_in)
|
|
|
return true;
|
|
|
}
|
|
|
|
|
|
- auto secondPkgDirGen =
|
|
|
- cmProjectDirectoryListGenerator{ this->Names, this->SortOrder,
|
|
|
- this->SortDirection };
|
|
|
-
|
|
|
// PREFIX/(Foo|foo|FOO).*/(lib/ARCH|lib*|share)/cmake/(Foo|foo|FOO).*/
|
|
|
if (TryGeneratedPaths(searchFn, prefix, firstPkgDirGen, cmnGen, cmakeGen,
|
|
|
secondPkgDirGen)) {
|