| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version |
Arguments: &key log vecp env remote-command prefix remote-host suffix image lisp flags infile opts args debug
When this function is used to start a second Lisp image, most of the
other functions in this document are not available since the client-lisp
infrastructure is
not enabled. This function is used by run-other-client and may be useful in
situations where an application needs behavior outside of the scope of
this document.
This is a more primitive function (than run-other-client) to start a new Allegro CL Lisp image. There is no implied calling or loading performed by this call. The values returned by run-other-lisp are the same as the value returned by run-shell-command.
If the log argument is non-nil
, it must be a string that denotes a file. The new
Lisp image will start a dribble there.
The vecp argument is only used on Unix.
When the vecp argument is non-nil
(the default), the command is passed to run-shell-command as a vector of
strings.
The env argument is an association list of environment variable names and values. The environment variables are added to the OS environment of the new Lisp image
The remote-command argument may be a string or a list of strings. The flattened sequence of strings is used as the command that starts the new Lisp image. The default is "rsh". If the command consists of several tokens it is recommended to pass it as a list of strings instead of a single string of tokens and spaces.
The prefix argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The remote-host argument is a string that
names the host where the new Lisp image must run. If omitted or
nil
, the value "localhost" is used.
The suffix argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The image argument may be a string that names the Lisp image file for the new Lisp image.
The lisp argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The flags argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The infile argument may be a string or a list of strings. Each string names a file that is loaded in the new Lisp image with a -L flag.
The opts argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The args argument may be a string or a list of strings. The flattened sequence of strings is inserted in the command that starts the new Lisp image.
The debug argument, when
non-nil
, causes the run-shell-command arguments to be printed
to *standard-output*
.
The arguments to run-other-lisp are used to construct an operating system command string from three main components. The components are concatenated into a single command that is invoked with run-shell-command.
<remote-command> <prefix> <remote-host> <suffix>
Each of the items in the first component may be a single string or a list of strings. Each string is passed as a separate argument in the OS command. Thus, if an item consists of several OS tokens, they should be presented as a list of strings; otherwise, they will not be recognized as separate arguments.
If the calling image is an IDE image, it is unlikely that the client image should be an IDE image; therefore it is necessary to specify this argument explicitly.
If the client image is to run on a separate host, then the lisp argument must be specified.
<lisp-command>
<flags> <-I image> <-d log> <-L infile>... <opts> -- <args>
The flags, opts, and args arguments may be any combination of lists and strings. Any list structure is flattened out and the resulting elements are separated by spaces in the command string, or appear as separate elements in the command vector.
If the image argument is not specified, the <-I image> part is omitted.
If the infile argument is not specified, the <-L infile> part is omitted. If the infile argument is a list, then multiple <-L> parts are inserted.
If the case-modes of the calling and client images are different, then the applications are responsible for passing information in a way that is compatible with the respective case-mode values. If symbols are specified as lowercase package-qualified strings, then case-mode issues are generally avoided.
To run a second Lisp image on the same host as the caller, almost all the arguments may be omitted:
(run-other-lisp)
is sufficient to start a second Lisp image that simply waits for some top-level input.
(run-other-lisp :infile "foo.cl")
will start a second Lisp image that loads "foo.cl" during startup.
(run-other-lisp :remote-host "spot" :lisp "~/bin/start-lisp" :args '("-flag1" "-flag2"))
will start a Lisp image on host "spot". The script "~/bin/start-lisp" is assumed to contain whatever is needed to start a Lisp on that host. The two argumtens "-flag1" "-flag2" will be added to the command line after the "--" separator.
See Running several communicating Allegro CL images in rpc.htm for information on running several Lisp images.
Copyright (c) 1998-2022, Franz Inc. Lafayette, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2019.8.20.
| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version |