Subject: Re: How to permanently add libraries to my clisp installation?
From: rpw3@rpw3.org (Rob Warnock)
Date: Wed, 08 Aug 2007 03:54:29 -0500
Newsgroups: comp.lang.lisp
Message-ID: <QeSdnWJ1wOBYGSTbnZ2dnUVZ_g6dnZ2d@speakeasy.net>
Eli Bendersky  <eliben@gmail.com> wrote:
+---------------
| My question pertains to CLISP on Windows. I'm looking for an accepted
| way to have some libraries (downloaded from the web, for instance)
| permanently available in my CL coding with CLISP. For example the ASDF
| library which isn't preinstalled with CLISP but can be easily obtained
| as a single .lisp file online. How can I make ASDF always available
| for my lisp code ? What is the best way to achieve this ?
+---------------

The classic method for *most* Lisps, not just CLISP, is to load
everything you want into a running Lisp image, save the image, and
then move the default Lisp image out of the way and replace it with
the one you just saved. You will probably want to make the "initial
function" of your custom image do (most of) the same things the
default initial function does, e.g., parse command-line options,
start a top-level REPL, etc., so it behaves just like a standard
image, except it's got more "stuff" in it. [But you can also use
this opportunity to add some special command-line options of your
own, if you like.]

For CLISP, the function to look at is SAVEINITMEM; for CMUCL,
it's SAVE-LISP; for SBCL it's SB-EXT:SAVE-LISP-AND-DIE, etc.
<http://www.faqs.org/faqs/lisp-faq/part2/section-11.html> has
a longer list [possibly out of date].


-Rob

-----
Rob Warnock			<rpw3@rpw3.org>
627 26th Avenue			<URL:http://rpw3.org/>
San Mateo, CA 94403		(650)572-2607