Hi,
I'm not sure if I miss something, but this mail seems to be sent to the
ecl-devel-owner@common-lisp.net . Correct ML address is
ecl-devel@common-lisp.net . I'm fast forwarding the mail there.
Brian Beckman writes:
> Hello --
>
> I am experimenting with ECL for actual embedded applications
> (in the sense of "embedded systems," i.e., small computers running
> disconnected controller software.
>
> The hardware team insists on inspecting the generated C code from
> the ECL compiler. I found, in the ECL manual, directions for
> producing .o files, .a files, .fasl files, and standalone executables.
> I also found prose that says that it is possible to emit the
> actual .c and .h files. However, I can't find instructions on how
> to emit the actual .c and .h files.
Generated code is readable, but it's a generated code after all. It's
not pretty.
>
> I can (compile-file "hello.lisp" :system-p t), but that produces
> only a .o file. I need to see the .c and .h files. My hardware
> team won't permit ECL-generated code until they can visually read
> and inspect the generated .c and .h files.
To prevent ECL from deleting these intermediate files you need to set
special variable c::*delete-files* to nil.
(setf c::*delete-files* nil)
Intermediate files are *.c, *.h and *.data . The last one contains some
untranslatable expressions (rare occasion – if you work with infinities
for instance) and debugging/reflection information (like the path to the
source file).
This problem has been tacled by Earl Ducaine here:
https://github.com/earl-ducaine/stupid-ecl-tricks-1 .
>
> Can you help me figure out how to generate them? I can't find
> the instructions in the manual. I am starting to read the source
> code, but perhaps you can give me correct pointers into the manual
> or some other kind of instructions.
I'm now in-process of revising manual and rewriting it into texi
sources. I'll keep in mind to document this. It would be great
if you could file an issue on
gitlab.com/embeddable-common-lisp/ecl/issues (with the label
"documentation"). Thanks!
>
> Thanks!
Regards,
Daniel
--
Daniel Kochmański | Poznań, Poland
;; aka jackdaniel
"Be the change that you wish to see in the world." - Mahatma Gandhi