All Manuals > LispWorks User Guide and Reference Manual > 40 The LISPWORKS Package

NextPrevUpTopContentsIndex

load-system

Function
Summary

Load each file of a system into the Lisp image if either the file has not been loaded, or the file has been written since it was last loaded.

Package

lispworks

Signature

load-system system-name &key force simulate source-only target-directory => nil

Arguments

system-name

A symbol representing the name of the system. The system must have been defined using the defsystem macro.

force

If t then all the files in the system are loaded regardless. (This argument was formerly called force-p. The old name is currently still accepted for compatibility.)

simulate

If nil or not present then load-system works silently. Otherwise a plan of the actions which load-system intends to carry out is printed. What happens next depends on the value of simulate:

t -- do nothing.

:ask -- you are asked, using y-or-n-p, if you want to carry out the plan.

:each -- load-system displays each action in the plan one at a time, and asks you if you want to carry out this particular action. The answer executes the rest of the plan without further prompting, e returns from load-system without further processing, and y and n work as expected.

source-only

If t the source files of the system are loaded. This only applies to file types where it makes sense to load a source file.

target-directory

This is the directory to search for the object files. If the object file cannot be found here then the source file from the system's default directory are loaded.

Examples
(load-system 'blackboard) (load-system 'tms :simulate :ask :source-only t)
Notes

For Lisp files load-system loads the object file (if it exists) into the image, unless over-ridden by the :source-only keyword argument. This behavior can be changed so that the newest file (whether source or object) is loaded by setting the variable *load-source-if-newer* to t.

C source files, for example foo.c, can be included in a system (see the use of :default-type and :type in defsystem). The corresponding object file name is foo.so on Linux, and on Unix it is foon.o where n is a platform-specific integer. On Windows the object file name is foo.dll.

See also

defsystem
compile-system
concatenate-system


LispWorks User Guide and Reference Manual - 13 Feb 2015

NextPrevUpTopContentsIndex