[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: defsystem
>> I've been trying to get rid of the interference by creating a defsystem
>> package for the pcl defsystem but it still interferes. Using another package
>> name (defsys) does not work either.
>>
>> Any suggestion?
Yes, the Allegro defsystem uses the "defsystem" (nicknames "defsys"
and "ds") package. Try another name.
>> Also, is there a documentation on Franz defsystem?
I've included the only documentation there is (an expanded version of
this or something similar to it will be put in our User Guide in the
future).
=============================================================================
;; -*- mode: text -*-
;; $Header: defsys.n,v 1.3 89/04/14 09:54:29 layer Exp $
A `system' is a list of modules. A `module' is a file plus some
information about the file and how it is to be processed.
Each system has a name, there is a 1-1 mapping between systems and
system names. Within a system each module has a name. The name of
the module is the filename (a namestring). Within a system there is a
1-1 mapping between modules and module names.
There are four operations you can do on systems:
1. compile-system: cause all modules to be `compiled'. This has
different meanings depending on the module.
2. load-system: cause the system to be loaded into the current lisp.
3. mapsystem: apply a user-supplied function to the modules that
make up the system.
4. show-system: describe the system and its modules.
In the description of functions below, a `system' argument refers to
the name of a system (a symbol or string naming the system). If
symbols are used, then the package in which the symbol resides has no
meaning.
defsystem system options {modules}+ [macro]
Create a new system with name SYSTEM and options taken from OPTIONS
(possibly nil). OPTIONS are keyword/value pairs, and the keywords
are:
:default-pathname
The system's default pathname or where to find the modules of
this system. This overrides *default-pathname-defaults* and is
overridden by a :pathname option to a module specification.
:default-package
The package in which modules are to be read. This overrides
*package* and is overridden by the :package option to a module
specification.
:needed-systems
A list of systems, or systems, on which this system depends.
They are compiled before compiling this system and loaded
before loading this system.
:load-before-compile
A list of systems, or systems, that are to be loaded before
this system is compiled.
MODULES are a either symbols which represent the module name (ie,
filename), or lists, with the car being the module name and the cdr
being a list of module options:
:load-before-compile
A list of module names that are to be loaded before this
module is compiled. Each module name can be either a symbol (a
module name in the same system) or a list of two items, the
car being the module name and the cadr being the system name).
:compile-satisfies-load
If the argument is non-nil, then this module is compiled and
not loaded.
:recompile-on
A list of modules which, if neededing recompilation
themselves, will cause this module to be recompiled.
:pathname
The pathname to this module. It is merged with the module
name to get the module pathname.
:package
The package in which this module is to be loaded or compiled.
:compile-function function
to compile this module, funcall 'function' and give it the
pathname of the file to compile.
:funcall-after function
:funcall-after-args args
After this module has been loaded, an (apply function args) is
done if the :funcall-after `symbol' is non-nil. Also, the
default-package or module package is still in effect when the
function is applied.
:load-after
A list of modules, or module names, which should be loaded
after this module is loaded. :load-after is done after
:funcall-after, and in the same package as the module which
loads it (the module may change its package, of course).
:object-type "string"
When this module is compiled the file type of the resulting
object file will be "string".
:target host
If `host' is eq to comp::.target., then this file is
considered `present' in the system, otherwise it is ignored
(during compile-system, etc).
:target-class arch
If `arch' is eq to comp::*target-class*, then this file is
considered `present' in the system, otherwise it is ignored
(during compile-system, etc).
undefsystem system [macro]
This removes knowledge of SYSTEM from the Lisp system.
load-system system &key :reload nil [function]
:include-components t
:interpreted nil
Load a system with name SYSTEM. If RELOAD is non-nil, then
load-system always reloads all the modules, otherwise only those
modules which have been recompiled or are out-of-date are loaded.
If INCLUDE-COMPONENTS is non-nil, then needed-systems, or
component subsystems, are loaded before loading this system. If
INTERPRETED is non-nil, then the source files for the system are
loaded instead of their compiled counterparts.
compile-system system &key :reload nil [function]
:recompile nil
:include-components t
Compile a system with SYSTEM. If RELOAD is non-nil, it has the
same effect as it does with load-system: any systems which are
loaded during compilation are loaded with this option. If
RECOMPILE is non-nil then recompile each module, even though it
may not need recompilation.
mapsystem function system [function]
Map FUNCTION over every module in SYSTEM, passing it three
arguments: module, class and target.
list-system-pathnames &rest systems [function]
This returns a list of strings, corresponding to the pathnames for
modules in each system given by SYSTEMS.
This could easily be implemented using MAPSYSTEM, but when this was
implemented MAPSYSTEM didn't exist.
show-system system [function]
This prints, in a nice way, the system and its properties.
*defsystem-systems* [variable]
A list of all the systems currently defined.
- References:
- defsystem
- From: rit@killdeer.stanford.edu (Jean-Francois Rit)