[Ecls-list] Build-shared-library gives multiple definitionserror

Daniel Dickison danieldickison at cmu.edu
Tue Aug 15 03:13:51 UTC 2006


On Aug 8, 2006, at 4:46 AM, Goffioul Michael wrote:
>>
>> ... I'd greatly appreciate
>> if you could point me to some documentation or tutorials on
>> how to make shared libraries loadable from C programs.
>
> The dynamic/static libraries won't init the ECL engine for you,
> you'll have to do it yourself in your code, using cl_boot function.
> Then you'll have to load your compiled library into the ECL engine:
> each compiled lib defines a function called init_XXXXX (XXXX stands
> for the module name); use this function with read_VV function as
>
> 	read_VV(OBJNULL, init_XXXXXX);
>
> This is what ECL does when loading a FASL file. After that, your
> code can call LISP functions either by using eval() or by calling
> directly the C equivalent.

I just tried this out, and I'm very excited to say that it works like  
a charm!  I'm quite astounded by how seamlessly it works, too (once  
you pointed me to the magic cl_boot and read_VV functions, anyways).   
Thanks a bunch for your help.

Daniel





More information about the ecl-devel mailing list