gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gcl-devel] Module


From: Leonardo Pereira
Subject: Re: [Gcl-devel] Module
Date: Sat, 25 Feb 2006 15:10:55 -0300

I wanna create an interface to possibility the creation of prograns using hurd libraries on GCL. So, I do not wanna rebuild GCL, I only wanna create a program that is linked to a library.

I will read a little more about that "clines" interface, I will try to find something on the docs. Anyway, If I build a program that uses that interface how it will work? It will be linked with the library?

2006/1/30, Mike Thomas <address@hidden>:
Hi Leonardo.
 
Welcome to GCL.


 
I wanna create a binding of a language to GCL. Is there any guide of how to do that?  
Can you please give an example of what you mean by "binding" as I don't understand your question?
 
If you want to call C from GCL there is a foreign function interface specifically designed for that purpose.  Here is come example code taken from the CVS file "mod/gcl_japi.lsp" :
 
========================================================
(clines "#include <japi.h>")
 
;; BOOLEAN  
(defconstant J_TRUE  1)
(defconstant J_FALSE 0)
(defentry j_fileselect ( int string string string ) ( string "j_fileselect" ))
(defentry j_messagebox ( int string string ) ( int "j_messagebox" ))
========================================================
 
It is also possible to rebuild GCL linked to external libraries with the "compiler::link" function
 
These functions are described in the GCL documentation.
 
Cheers
 
Mike Thomas.
 
 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]