aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--paludis/repository_so_loader.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/paludis/repository_so_loader.cc b/paludis/repository_so_loader.cc
index 67a78a3f7..e3cc96008 100644
--- a/paludis/repository_so_loader.cc
+++ b/paludis/repository_so_loader.cc
@@ -106,7 +106,9 @@ RepositorySoLoader::load_dir(const FSEntry & so_dir)
PALUDIS_VERSION_MINOR))(*d))
continue;
- void * dl(dlopen(stringify(*d).c_str(), RTLD_LOCAL | RTLD_NOW));
+ /* don't use RTLD_LOCAL, g++ is over happy about template instantiations, and it
+ * can lead to multiple singleton instances. */
+ void * dl(dlopen(stringify(*d).c_str(), RTLD_GLOBAL | RTLD_NOW));
if (dl)
dl_opened.push_back(dl);