Compiles AutoLISP source code into a FAS file
(vlisp-compile 'mode filename [out-filename])
- mode
- filename
- out-filename
-
A string identifying the compiled output file. If you do not specify an output file, vlisp-compile names the output with the same name as the input file, but replaces the extension with .fas.
Note that if you specify an output file name but do not specify a path name for either the input or the output file, vlisp-compile places the output file in the AutoCAD installation directory.
T, if compilation is successful; otherwise nil.
Assuming that yinyang.lsp resides in a directory that is in the AutoCAD support file search path, the following command compiles this program:
_$ (vlisp-compile 'st "yinyang.lsp")
T
The output file is named yinyang.fas and resides in the same directory as the source file.
The following command compiles yinyang.lsp and names the output file GoodKarma.fas:
(vlisp-compile 'st "yinyang.lsp" "GoodKarma.fas")
Note that the output file from the previous command resides in the AutoCAD installation directory, not the directory where yinyang.lsp resides. The following command compiles yinyang.lsp and directs the output file to the c:\my documents directory:
(vlisp-compile 'st " yinyang.lsp " "c:/my documents/GoodKarma")
This last example identifies the full path of the file to be compiled:
(vlisp-compile 'st "c:/program files/<AutoCAD installation directory>/Sample/yinyang.lsp")
The output file from this command is named yinyang.fas and resides in the same directory as the input file.
-
The
Compiling a Program from a File topic in the AutoLISP Developer's Guide.