Re: G_MODULE_BIND_LOCAL broke nautilus-python extension
- From: "Gustavo J. A. M. Carneiro" <gjc inescporto pt>
- To: Mike Hearn <mike plan99 net>
- Cc: nautilus-list gnome org, desktop-devel-list gnome org
- Subject: Re: G_MODULE_BIND_LOCAL broke nautilus-python extension
- Date: Fri, 10 Feb 2006 19:51:42 +0000
On Wed, 2006-02-08 at 20:02 +0000, Mike Hearn wrote:
> On Wed, 08 Feb 2006 16:22:08 +0000, Gustavo J. A. M. Carneiro wrote:
> > So it seems that the desktop wide decision to load all modules with
> > G_MODULE_BIND_LOCAL, for performance reasons, may break python
> > extensions. So far, nautilus-python was affected by this. Do people
> > have any suggestions? Clearly Python has to be fixed, but that is a
> > long term fix; how to fix things _now_?
>
> Try calling dlopen("libpython.so.<whatever>", RTLD_GLOBAL) before calling
> into the interpreter. If you're lucky that'll force the symbols into
> global scope. If you're unlucky then you need to not link against
> libpython yourself but instead dlopen and dlsym the APIs you need, and
> hope that they actually exist (libpython does not have a stable ABI).
This worked perfectly; thanks a lot! :-)
--
Gustavo J. A. M. Carneiro
<gjc inescporto pt> <gustavo users sourceforge net>
The universe is always one step beyond logic.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]