diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmLocalGenerator.cxx | 4 | ||||
-rw-r--r-- | Source/cmOrderLinkDirectories.cxx | 5 | ||||
-rw-r--r-- | Source/cmOrderLinkDirectories.h | 6 |
3 files changed, 9 insertions, 6 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 890e905..84b4902 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -1712,8 +1712,10 @@ void cmLocalGenerator orderLibs.SetLinkTypeInformation(cmOrderLinkDirectories::LinkShared, static_link_type_flag, shared_link_type_flag); - orderLibs.SetLinkPrefix( + orderLibs.AddLinkPrefix( this->Makefile->GetDefinition("CMAKE_STATIC_LIBRARY_PREFIX")); + orderLibs.AddLinkPrefix( + this->Makefile->GetDefinition("CMAKE_SHARED_LIBRARY_PREFIX")); orderLibs.AddLinkExtension( this->Makefile->GetDefinition("CMAKE_STATIC_LIBRARY_SUFFIX"), cmOrderLinkDirectories::LinkStatic); diff --git a/Source/cmOrderLinkDirectories.cxx b/Source/cmOrderLinkDirectories.cxx index ab3fe9c..fe00ec2 100644 --- a/Source/cmOrderLinkDirectories.cxx +++ b/Source/cmOrderLinkDirectories.cxx @@ -189,9 +189,10 @@ void cmOrderLinkDirectories::CreateRegularExpressions() // be the library name. Match index 3 will be the library // extension. reg = "^("; - if(!this->LinkPrefix.empty()) + for(std::set<cmStdString>::iterator p = this->LinkPrefixes.begin(); + p != this->LinkPrefixes.end(); ++p) { - reg += this->LinkPrefix; + reg += *p; reg += "|"; } reg += ")"; diff --git a/Source/cmOrderLinkDirectories.h b/Source/cmOrderLinkDirectories.h index 0da6e85..a3bc75a 100644 --- a/Source/cmOrderLinkDirectories.h +++ b/Source/cmOrderLinkDirectories.h @@ -83,11 +83,11 @@ public: } } // should be set from CMAKE_STATIC_LIBRARY_PREFIX - void SetLinkPrefix(const char* s) + void AddLinkPrefix(const char* s) { if(s) { - this->LinkPrefix = s; + this->LinkPrefixes.insert(s); } } // Return any warnings if the exist @@ -164,7 +164,7 @@ private: std::vector<cmStdString> SharedLinkExtensions; std::vector<cmStdString> LinkExtensions; // the names of link prefixes - cmStdString LinkPrefix; + std::set<cmStdString> LinkPrefixes; // set of directories that can not be put in the correct order std::set<cmStdString> ImpossibleDirectories; // Name of target |