[cffi-devel] support for .a libraries

Stephen Compall s11 at member.fsf.org
Fri Jan 20 14:14:40 UTC 2006


On Fri, 2006-01-20 at 05:23 +0000, Alexis Gallagher wrote:
> I was wondering if define-foreign-library can currently handle libraries 
> that are in the "ar" archive format.

It is a UNIX limitation, not a Lisp one, that archives cannot be mapped
as executable memory.  The reasons for this have to do with
"position-independent code"; for further information, search that term.

The reason .so libraries were created, in fact, was to offer a
dynamically-loadable alternative to archives, which you will find are
little more than balls of .o files.

I recommend that you obtain a .so version of your library.  For help
with this, I suggest contacting the library's maintainer(s).

-- 
Stephen Compall
http://scompall.nocandysw.com/blog




More information about the cffi-devel mailing list