diff options
Diffstat (limited to 'Source/cmFindPackageCommand.cxx')
-rw-r--r-- | Source/cmFindPackageCommand.cxx | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx index 60de74f..fe4cc54 100644 --- a/Source/cmFindPackageCommand.cxx +++ b/Source/cmFindPackageCommand.cxx @@ -92,6 +92,7 @@ cmFindPackageCommand::cmFindPackageCommand() this->DebugMode = false; this->UseLib32Paths = false; this->UseLib64Paths = false; + this->UseLibx32Paths = false; this->PolicyScope = true; this->VersionMajor = 0; this->VersionMinor = 0; @@ -173,6 +174,13 @@ bool cmFindPackageCommand::InitialPass(std::vector<std::string> const& args, this->UseLib64Paths = true; } + // Lookup whether libx32 paths should be used. + if (this->Makefile->PlatformIsx32() && + this->Makefile->GetState()->GetGlobalPropertyAsBool( + "FIND_LIBRARY_USE_LIBX32_PATHS")) { + this->UseLibx32Paths = true; + } + // Check if User Package Registry should be disabled if (this->Makefile->IsOn("CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY")) { this->NoUserRegistry = true; @@ -1165,7 +1173,6 @@ void cmFindPackageCommand::FillPrefixesSystemRegistry() #if defined(_WIN32) && !defined(__CYGWIN__) #include <windows.h> -#undef GetCurrentDirectory // http://msdn.microsoft.com/en-us/library/aa384253%28v=vs.85%29.aspx #if !defined(KEY_WOW64_32KEY) #define KEY_WOW64_32KEY 0x0200 @@ -2002,6 +2009,9 @@ bool cmFindPackageCommand::SearchPrefix(std::string const& prefix_in) if (this->UseLib64Paths) { common.push_back("lib64"); } + if (this->UseLibx32Paths) { + common.push_back("libx32"); + } common.push_back("lib"); common.push_back("share"); |