![](https://secure.gravatar.com/avatar/3de24d0a4ca9b7683fea067b74510820.jpg?s=120&d=mm&r=g)
On Monday, April 24, 2006, at 04:50PM, James Bielman <jamesjb@jamesjb.com> wrote:
hbabcockos1@mac.com writes:
I'm having trouble loading libraries using CFFI 0.9.0 on debian. Example:
Gives: Unable to load foreign library: libc.so [Condition of type LOAD-FOREIGN-LIBRARY-ERROR]
Taking a guess here, but I'd bet that your /usr/lib/libc.so is actually a linker script. I'm not sure what dlopen is defined to do in this case, but you are probably better off loading "libc.so.6"
Thanks! That was the problem. I was also having trouble loading another library, located in /usr/local/lib. That doesn't seem to be in the default library search path on my debian box, though it is on my OS-X box. Or at least that is my guess based on this working (in the context of define-foreign-library): (:unix "/usr/local/lib/libplplotd.so") and this not working: (:unix "libplplot") However, maybe I didn't set something up correctly? For SBCL, does CFFI use sb-alien:load-shared-object to load the library? best, -Hazen