Hi,
Michael Goffioul, one of the developers of ECL, has passed some patches which port cffi-luis to the CVS version of ECL.
The changes include support for callbacks and also for dynamic loading of libraries, calling of foreign functions which are defined in these libraries and also runtime definition of C variables.
Please feel free to incorporate this into your source tree. All tests are passed except for one that has a memory leak.
Juanjo