[Ecls-list] using ECL's shared libraries in C programs
Juan Jose Garcia-Ripoll
jlr at mpq.mpg.de
Mon Mar 25 01:18:02 UTC 2002
On Saturday 23 March 2002 17:19, franco smith wrote:
> yo
> i'm trying to use a shared library created from a lisp file by ECL in a C
> program my test lisp file looks like that:
>
> (defun my_function () 9)
>
> i give the following commands to ECL:
>
> (compile-file "test.lsp" :system-p t)
> (c:build-shared-library (c:shared-library-pathname "mytest") :lisp-files
> '("test.o"))
> now, i have absolutely no idea how to go on ;)
Hi,
I have been reading both of your messages. ECL is not prepared, currently, to
be arbitrarily linked into a C program. The linking phase has to be performed
by ECL. I placed some examples both in the mailing list and in the manual.
Basically, you have to use c:build-program providing it with the names of the
lisp and C libraries (this includes your C code) that you want to include.
Maybe that is the cause of the problem, because eval(...) should return the
output of the function.
Regards
Juanjo
More information about the ecl-devel
mailing list