On Mon, Apr 14, 2008 at 3:24 PM, Emmanuele Bassi <[EMAIL PROTECTED]> wrote:
>  I'd like for somebody with an nvidia card to test compiling the
>  pyclutter bindings to apply this change:
>
>   # linker flags
>  - common_ldflags = -module -avoid-version
>  + common_ldflags = -module -avoid-version -rdynamic

~$ lspci | grep -i nvidia
01:00.0 VGA compatible controller: nVidia Corporation GeForce 8400M GS (rev a1)

~$ python -c "import clutter"
Woo!1!!

** (-c:25584): WARNING **: failed to bind GLXGetProcAddress or
GLXGetProcAddressARB

diff --git a/clutter/Makefile.am b/clutter/Makefile.am
index 1b4f49f..28953eb 100644
--- a/clutter/Makefile.am
+++ b/clutter/Makefile.am
@@ -24,7 +24,7 @@ pkgincludedir =
$(includedir)/pyclutter-$(PLATFORM_VERSION)/pyclutter
 pkginclude_HEADERS = pyclutter.h

 # linker flags
-common_ldflags = -module -avoid-version
+common_ldflags = -module -avoid-version -rdynamic

 # clutter module
 CLUTTER_DEFS = clutter-base.defs
diff --git a/clutter/Makefile.in b/clutter/Makefile.in
index abf19f6..5845f62 100644
--- a/clutter/Makefile.in
+++ b/clutter/Makefile.in
@@ -262,7 +262,7 @@ pyclutter_PYTHON = __init__.py keysyms.py deprecation.py
 pkginclude_HEADERS = pyclutter.h

 # linker flags
-common_ldflags = -module -avoid-version
+common_ldflags = -module -avoid-version -rdynamic

 # clutter module
 CLUTTER_DEFS = clutter-base.defs
diff --git a/clutter/cluttermodule.c b/clutter/cluttermodule.c
index 34435b8..b4c41e6 100644
--- a/clutter/cluttermodule.c
+++ b/clutter/cluttermodule.c
@@ -35,6 +35,7 @@ init_clutter (void)
 {
   PyObject *m, *d;

+  puts("Woo!1!!");
   init_pygobject_check (2, 12, 0);

   clutter_base_init ();

>  and see if it fixes it.

Nope. Now, I remember something about this from the old days when I
would write JNI code. When Java would load JNI extensions, he'd use
particular flags sent to dlopen which would block symbols from being
promoted to the global namespace. This may be a good idea, since
slamming symbols over the top of already existing symbols in the
global namespace might be bad.

So maybe they call dlopen(pyclutter, RTLD_LOCAL) or some flag that
prevents this promotion of symbols to the global namespace. Which I'm
not sure we can override at compile / link time.

Blake
-- 
Blake Ramsdell | http://www.blakeramsdell.com
N�����r��zǧu���[hr[�����{.n�+������r�

Reply via email to