Subject: [clisp-list] (compile-file "foo.lisp") deletes foo.c ??

From: "Hoehle, Joerg-Cyril" <[email-masked]>
Date: Wed Mar 19 06:43:11 2003

Hi,

I'd like to jump on the occasion to query whether it's acceptable that a C file and C forms be generated for a Lisp file which would contain only definitions for shared library functions?
The C file might never be used by CLISP.
It may, however, serve as a basis for replacing some of the functions with hand-written wrappers, providing better integration into Lisp, or for whatever purpose.

The complication is that I have thoughts on a Lisp-level interface where the Lisp file will contain no indication as to whether a foreign function will eventually come from a shared library or a link module. The .fas file would be portable.

(DEF-CALL-OUT ... (:library "mysql") #)
would emit code which would only at load-time choose among looking up a shared library or a link module, depending on the user's settings for the "mysql" module -- probably a shared library on MS-Windows, and a static module on CLISP -- but this is just an example.

Thanks for your ideas,
	Jorg Hohle.

---

From: [email-masked] (Don Cohen)
Date: Wed Mar 19 09:13:10 2003

Hoehle, Joerg-Cyril writes:
 > Hi,
 > 
 > I'd like to jump on the occasion to query whether it's acceptable
   that a C file and C forms be generated for a Lisp file which would
   contain only definitions for shared library functions? 
 > The C file might never be used by CLISP.

I now think the important point is that the generated .c file 
is not needed to load the .fas file.
This suggests that it should be generated by some function 
other than compile-file:
(compile-FF "foo.lisp" &key output-file)
If the default of this were to overwrite foo.c it wouldn't be 
nearly so bad, though I would still prefer a default of foo-FF.c