Re: [cffi-devel] close-foreign-library assert

2013-03-22 Thread nan
On Fri, 22 Mar 2013 11:02:38 +0200, Luís Oliveira wrote: Interesting. Any clue why the shared dependencies are tickling the glibc assertion? I have no idea. Other than this one i didn't have any issues with having 4 shared libraries. If i find why, you'll be first to know. _

Re: [cffi-devel] close-foreign-library assert

2013-03-22 Thread Luís Oliveira
On Fri, Mar 22, 2013 at 7:27 AM, nan wrote: > Tested both libtest.so and my library, loading/unloading libtest.so was > fine. So i tried removing shared dependencies of my library (i actually had > 4 shared libraries, cffi dynamically loads one of them, the one that > dynamically linked to other 3

Re: [cffi-devel] close-foreign-library assert

2013-03-22 Thread nan
On Thu, 21 Mar 2013 22:47:54 +0200, Luís Oliveira wrote: cffi-tests tries to load cffi-libffi which requires libffi's development headers. You don't need to actually load cffi-tests though. Just cd into the tests/ directory and run make to compile libtest.so. Tested both libtest.so and my l

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread Luís Oliveira
On Thu, Mar 21, 2013 at 12:20 PM, nan wrote: > For this one, i tried using all the compilers i got, After (ql:quickload > :cffi-tests), all stuck at: [...] > fatal error: ffi.h: No such file or directory cffi-tests tries to load cffi-libffi which requires libffi's development headers. You don't n

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread nan
On Thu, 21 Mar 2013 13:14:39 +0200, Luís Oliveira wrote: In any case, it would be nice to come up with a minimal reproducible test case. First off, do you see the same error if you try to load and reload the libtest.so library that comes with the CFFI test suite? For this one, i tried using

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread nan
On Thu, 21 Mar 2013 13:14:39 +0200, Luís Oliveira wrote: CCL would be a good one to try. It's easy to download a binary following the instructions from their website. In any case, it would be nice to come up with a minimal reproducible test case. First off, do you see the same error if you t

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread Luís Oliveira
On Thu, Mar 21, 2013 at 11:10 AM, nan wrote: > cmucl gives the same error. > ecl takes the easy way out, %close-foriegn-library not implemented (which is > so much better than that assert) > clisp looks like it works, returns T. > ccl couldn't manage to install it with archlinux-aur package CCL w

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread nan
On Thu, 21 Mar 2013 12:50:25 +0200, Luís Oliveira wrote: On Thu, Mar 21, 2013 at 10:22 AM, nan wrote: In addition to that, since sbcl calls dlopen with RTLD_GLOBAL|RDLD_NOW flags, i tried that too, all works as expected. In that case, can you try it with another Lisp? cmucl gives the sa

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread Luís Oliveira
On Thu, Mar 21, 2013 at 10:22 AM, nan wrote: > In addition to that, since sbcl calls dlopen with RTLD_GLOBAL|RDLD_NOW > flags, i tried that too, all works as expected. In that case, can you try it with another Lisp? -- Luís Oliveira http://r42.eu/~luis/

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread nan
On Thu, 21 Mar 2013 11:50:42 +0200, Luís Oliveira wrote: A Google search for that error string turns up this: . Perhaps your library is being marked as RTLD_NODELETE by glibc as described in that bug report. I suppose a good way to check

Re: [cffi-devel] close-foreign-library assert

2013-03-21 Thread Luís Oliveira
On Thu, Mar 21, 2013 at 4:53 AM, nan wrote: > I am working on a project which used to be completely in C++, now i am > gradually moving some of it to CL. For this reason i need to work on both > sides, which requires me to reload cffi bindings too often. I couldn't find > anything related to this