diff options
Diffstat (limited to 'cpp/src/Ice/DynamicLibrary.cpp')
-rw-r--r-- | cpp/src/Ice/DynamicLibrary.cpp | 34 |
1 files changed, 22 insertions, 12 deletions
diff --git a/cpp/src/Ice/DynamicLibrary.cpp b/cpp/src/Ice/DynamicLibrary.cpp index a62fe7093df..75985b6ab06 100644 --- a/cpp/src/Ice/DynamicLibrary.cpp +++ b/cpp/src/Ice/DynamicLibrary.cpp @@ -22,7 +22,7 @@ using namespace std; IceUtil::Shared* IceInternal::upCast(DynamicLibrary* p) { return p; } IceUtil::Shared* IceInternal::upCast(DynamicLibraryList* p) { return p; } -IceInternal::DynamicLibrary::DynamicLibrary() : +IceInternal::DynamicLibrary::DynamicLibrary() : _hnd(0) { } @@ -89,24 +89,23 @@ IceInternal::DynamicLibrary::loadEntryPoint(const string& entryPoint, bool useIc if(comma == string::npos) { libName = libSpec; -# if defined(ICE_CPP11) && defined(__GLIBCXX__) +# if defined(ICE_CPP11_MAPPING) && !defined(_WIN32) libName += "++11"; # endif if(useIceVersion) { int majorVersion = (ICE_INT_VERSION / 10000); int minorVersion = (ICE_INT_VERSION / 100) - majorVersion * 100; + int patchVersion = ICE_INT_VERSION % 100; ostringstream os; os << majorVersion * 10 + minorVersion; - - int patchVersion = ICE_INT_VERSION % 100; - if(patchVersion > 50) + if(patchVersion >= 60) { - os << 'b'; - if(patchVersion >= 52) - { - os << (patchVersion - 50); - } + os << 'b' << (patchVersion - 60); + } + else if(patchVersion >= 50) + { + os << 'a' << (patchVersion - 50); } version = os.str(); } @@ -119,7 +118,7 @@ IceInternal::DynamicLibrary::loadEntryPoint(const string& entryPoint, bool useIc return 0; } libName = libSpec.substr(0, comma); -# if defined(ICE_CPP11) && defined(__GLIBCXX__) +# if defined(ICE_CPP11_MAPPING) && !defined(_WIN32) libName += "++11"; # endif version = libSpec.substr(comma + 1); @@ -130,6 +129,13 @@ IceInternal::DynamicLibrary::loadEntryPoint(const string& entryPoint, bool useIc #ifdef _WIN32 lib += libName; lib += version; +# ifdef ICE_OS_WINRT + lib += "uwp"; +# endif + +# ifdef ICE_CPP11_MAPPING + lib += "++11"; +# endif # if defined(_DEBUG) && !defined(__MINGW32__) lib += 'd'; @@ -273,9 +279,13 @@ IceInternal::DynamicLibrary::getErrorMessage() const return _err; } +IceInternal::DynamicLibraryList::~DynamicLibraryList() +{ + // Out of line to avoid weak vtable +} + void IceInternal::DynamicLibraryList::add(const DynamicLibraryPtr& library) { _libraries.push_back(library); } - |