On 02/17/2012 06:06 PM, Myrosia Dzikovska wrote:
> I am considering moving to sbcl from Allegro CL. I work on a
> that involves a bunch of components written in different
> communicating using ICE middleware (http://www.zeroc.com).
There is no
> "native" ICE interface for LISP, and none is planned anytime
> There are C and Python interfaces. The protocol requirements
> complex enough that I don't have time to implement these in
> My solution so far has been as follows: have the ICE server
> running in C++, accepting requests. When a request comes in,
> code calls a lisp call handler, eventually gets the results
> passes them to the caller. Calling LISP from C is possible,
> awkward, in Allegro CL.
> Sbcl manual says that calling LISP from C is hackish and
> supported, and does not provide any detail. In practice,
doing this in
> ACL is extremely hackish as well, with various issues and
> restrictions. But it was documented enough for me to make it
> Has anyone had any experience with calling lisp from C in
> like to know if this is worth my time, or I should look for a
> different LISP distribution. I'd consider alternatives to
> calling LISP from C, e.g., if it would be possible to have a
> sleeping in LISP and woken up from C (but it's not obvious to
> it would work from the manuals, either).
Have you tried using CFFI ? CFFI provides macros for defining
callbacks; but more importantly provides a uniform API between
different lisp implementations for interfacing with foreign code.