Function Entry: CLAL-COMPILE-FILE
← Prev | ↑ Chapter | Next → | Index | Symbols
Function Entry: CLAL-COMPILE-FILE
Name
clal-compile-file
Class
clautolisp Extension Function
Syntax
(clal-compile-file source-file [output-file])
Arguments and Values
source-file— a string naming an AutoLISP source file, resolved the wayloadresolves its argument.output-file(optional) — a string naming the artefact. When omitted, the source name with type.lap, beside the source.
Description
Compile source-file into a .lap compiled application.
A .lap is a native host FASL, renamed — the clautolisp analogue of
AutoCAD .fas and BricsCAD .des. It loads into a running image
alongside other applications, which is what an AutoLISP application has
to be, and it is therefore specific to the host Lisp (SBCL or CCL) and
to the clautolisp version that built it. Builds that differ are kept in
different directories, not distinguished by name.
This compiles; it does not load. That is the division Common Lisp makes
between compile-file and load, and the one vlisp-compile makes.
Unlike the compilation that happens on its own during load, this does
not consult SPEED: the qualities govern what the engine does on its
own initiative, not what it does when told.
Return Values
T when the artefact was written; nil when the source could not be
located (with errno 73) or the host compiler failed — the same
contract vlisp-compile has.
Side Effects
Writes the artefact. Does not define anything in the calling image.
Exceptional Situations
Signals :compiler-not-available in a clautolisp built without the
compiler. Signals from require-string when source-file is not a
string. A missing source is reported by the return value.
Examples
(clal-compile-file "geometry.lsp") => T ; wrote geometry.lap (load "geometry.lap")
Availability
- clautolisp: since 2.0.9; writes a
.lapsince 2.0.10. - AutoCAD: NOT present.
- BricsCAD: NOT present.
Source Notes
- clautolisp-only extension; specified by pjb 2026-08-27. The vendor
analogue is
vlisp-compile, which writes an artefact.