Group :: Development/Tools
RPM: cmake
Main Changelog Spec Patches Sources Download Gear Bugs e FR Repocop
Patch: alt-fallback-modules-dir.patch
Download
Download
--- a/Source/cmMakefile.cxx~ 2017-09-07 19:14:26.000000000 +0300
+++ b/Source/cmMakefile.cxx 2017-10-23 12:55:36.616269687 +0300
@@ -3359,6 +3359,25 @@ std::string cmMakefile::GetModulesFile(c
}
}
+ {
+ const char* cmakeModulePathFallback = "/usr/share/CMake/Modules";
+ std::vector<std::string> modulePath;
+ cmExpandList(cmakeModulePathFallback, modulePath);
+
+ // Look through the possible module directories.
+ for (std::vector<std::string>::iterator i = modulePath.begin();
+ i != modulePath.end(); ++i) {
+ std::string itempl = *i;
+ cmSystemTools::ConvertToUnixSlashes(itempl);
+ itempl += "/";
+ itempl += filename;
+ if (cmSystemTools::FileExists(itempl.c_str())) {
+ moduleInCMakeModulePath = itempl;
+ break;
+ }
+ }
+ }
+
// Always search in the standard modules location.
moduleInCMakeRoot = cmSystemTools::GetCMakeRoot();
moduleInCMakeRoot += "/Modules/";