Skip to content

Commit a017ec0

Browse files
author
g_j_m
committed
Fix to allow compilation on windows and OSX
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@4959 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 1fe9b59 commit a017ec0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/gui/qgspluginmanager.cpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ sharedLibExtension = "*.so*";
8888
std::cout << "PLUGIN MANAGER:" << std::endl;
8989
for (unsigned i = 0; i < pluginDir.count(); i++)
9090
{
91+
QString lib = QString("%1/%2").arg(txtPluginDir->text()).arg(pluginDir[i]);
92+
9193
#ifdef TESTLIB
9294
// This doesn't work on WIN32 and causes problems with plugins
9395
// on OS X (the code doesn't cause a problem but including dlfcn.h
@@ -97,7 +99,7 @@ sharedLibExtension = "*.so*";
9799
// This doesn't work on WIN32 and causes problems with plugins
98100
// on OS X (the code doesn't cause a problem but including dlfcn.h
99101
// renders plugins unloadable)
100-
QString lib = QString("%1/%2").arg(txtPluginDir->text()).arg(pluginDir[i]);
102+
101103
// void *handle = dlopen((const char *) lib, RTLD_LAZY);
102104
void *handle = dlopen(lib.toLocal8Bit().data(), RTLD_LAZY | RTLD_GLOBAL);
103105
if (!handle)

0 commit comments

Comments
 (0)