[pypy-commit] pypy reflex-support: force RTLD_GLOBAL

wlav noreply at buildbot.pypy.org
Sat Aug 6 08:41:32 CEST 2011


Author: Wim Lavrijsen <WLavrijsen at lbl.gov>
Branch: reflex-support
Changeset: r46304:717259eb7a76
Date: 2011-08-05 11:06 -0700
http://bitbucket.org/pypy/pypy/changeset/717259eb7a76/

Log:	force RTLD_GLOBAL

diff --git a/pypy/module/cppyy/capi/cint_capi.py b/pypy/module/cppyy/capi/cint_capi.py
--- a/pypy/module/cppyy/capi/cint_capi.py
+++ b/pypy/module/cppyy/capi/cint_capi.py
@@ -1,7 +1,8 @@
 import py, os
 
 from pypy.translator.tool.cbuild import ExternalCompilationInfo
-from pypy.rpython.lltypesystem import rffi, lltype
+from pypy.rpython.lltypesystem import rffi, lltype, ll2ctypes
+from pypy.rlib import rdynload
 
 pkgpath = py.path.local(__file__).dirpath().join(os.pardir)
 srcpath = pkgpath.join("src")
@@ -14,12 +15,14 @@
     rootincpath = []
     rootlibpath = []
 
+ll2ctypes.load_library_kwargs['mode'] = rdynload.RTLD_GLOBAL | rdynload.RTLD_NOW
+
 eci = ExternalCompilationInfo(
     separate_module_files=[srcpath.join("cintcwrapper.cxx")],
     include_dirs=[incpath] + rootincpath,
     includes=["cintcwrapper.h"],
     library_dirs=rootlibpath,
-    link_extra=["-lRIO", "-lThread", "-lCore", "-lCint", "-lm", "-ldl", "-rdynamic"],
+    libraries=["Cint", "Core"],
     use_cpp_linker=True,
 )
 


More information about the pypy-commit mailing list