On Mon, 09 Aug 2010 13:49:43 Andy Kittner <and...@gmx.de> wrote: > > > I made the test in Vim 7.3: After removing RTLD_GLOBAL there wasno crash > > > any more. > > > > If I'm not mistaken this flag was added to make "import termios" work. > > Or something like that. > > The issue was that at least on some systems pythons C-Extensions seemingly > aren't linked against the python shared library, therefore they can't be > imported unless the host application provides the required symbols. > > See this thread: "Linking errors when compiled with both python and python3" > http://groups.google.com/group/vim_dev/browse_frm/thread/10be77eb81ad1c2d/fed7c6d9e3932ef5?tvc=1
Hi Bram, I missed that thread. I had the same problem with PyQt 4.7, first, but at a later try it worked, probably because that linked against libpython 3.1.2. Andy reported termios to work as well on his system. Maybe the problematic termios was older or not linked against libpython, because it was not there at the time termios was configured. Maybe we can optimistically assume that for most python libraries / systems it works. I would opt for the following: If only one, Python 2.x xor Python 3.x, is configured (and if DYNAMIC_PYTHON), then use RTLD_GLOBAL: #define load_dll(n) dlopen((n), RTLD_LAZY|RTLD_GLOBAL) If both are configured use without RTLD_GLOBAL: #define load_dll(n) dlopen((n),RTLD_LAZY) -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php