[Openmcl-devel] Simple C FFI example for OS X?

Peter Seibel peter at javamonkey.com
Mon Feb 2 21:52:24 PST 2004

Does anyone have a really trivial example of how to write some C code
and call it from openmcl on OS X? I looked through the examples and it
seemed that most of the OS X examples were Cocoa-based while the plain
C examples were for LinuxPPC? I'm mostly interested in the mechanics
of how to compile my C code so I can load it in Lisp and then call my
functions. Like I said trivial stuff, but I'd rather cut-n-paste than
figure it out from first principles if I can.

FWIW, I'm working on hooking up to the QuickTime Music Architecture
functions to play some music. My current theory is to write a thin
layer in C that provides just the API I need in a way that will be
convenient to call from Lisp and then do the rest up in Lisp.
(Basically I need to be able to generate chunks of memory with
QuickTime music events encoded in them and then stuff them into a
TunePlayer and tell it to play them. No rocket science.)


Peter Seibel                                      peter at javamonkey.com

         Lisp is the red pill. -- John Fraser, comp.lang.lisp

More information about the Openmcl-devel mailing list