1
1
openmpi/config/libltdl_dlopen_global.diff
Jeff Squyres 176cecfb3b Fix for LT 2.1 libltdl lt_dlopen behavior of putting loaded DSO's in a
private scope.  Solves the problem of Red Hat-provided OFED not
working properly because the libibverbs plugins are not linked
against libibverbs.

This commit was SVN r13926.
2007-03-05 17:21:42 +00:00

30 строки
785 B
Diff

--- opal/libltdl/loaders/dlopen.c 2007-03-05 08:56:11.000000000 -0800
+++ opal/libltdl/loaders/dlopen_global.c 2007-03-05 08:54:46.000000000 -0800
@@ -121,6 +121,17 @@
# define LT_LAZY_OR_NOW 0
#endif /* !LT_LAZY_OR_NOW */
+/* Open MPI */
+#if !defined(LT_GLOBAL)
+# if defined(RTLD_GLOBAL)
+# define LT_GLOBAL RTLD_GLOBAL
+# else
+# if defined(DL_GLOBAL)
+# define LT_GLOBAL DL_GLOBAL
+# endif
+# endif /* !RTLD_GLOBAL */
+#endif
+
#if defined(HAVE_DLERROR)
# define DLERROR(arg) dlerror ()
#else
@@ -136,7 +147,7 @@
static lt_module
vm_open (lt_user_data LT__UNUSED loader_data, const char *filename)
{
- lt_module module = dlopen (filename, LT_LAZY_OR_NOW);
+ lt_module module = dlopen (filename, LT_GLOBAL | LT_LAZY_OR_NOW);
if (!module)
{