On 10/25/10 4:05 AM, Leo Butler wrote:
>
> On Sun, 24 Oct 2010, Raymond Toy wrote:
>
> < We currently have a function, share-subdir-list (in src/init-cl.lisp),
> < to compute the list of subdirectories of share, which eventually becomes
> < the list of share directories that maxima searches.
> <
> < However, this only exists for a handful of Lisps like ccl (new), clisp,
> < cmucl, ecl, and sbcl. For other lisps, we use a hand-edited list of
> < directories which has to be edited whenever a new share directory is
> < added. This is error-prone.
> <
> < One way to make this automatic is to have configure produce the list of
> < subdirectories and substitute that list into the list in
> < default-share-subdirs-list. For this to work, we would need to move
> < init-cl.lisp to init-cl.lisp.in so that configure will process
> < init-cl.lisp.in to create init-cl.lisp, substituting in correct value of
> < into default-share-subdirs-list. (Actually, we can create a new file,
> < share-subdirs.lisp.in, so we don't mess up init-cl.lisp.)
> <
> < I've tested this and it produces the correct list.
> <
> < In fact, with this change, we can get rid of all of the special versions
> < of share-subdir-list function, and just use default-share-subdirs-list.
> < This is a win, I think.
>
> Ray, wouldn't it be better to have configure create a separate file
> holding the directory information and have init-cl.lisp read this?
> This seems like the more modular and maintainable solution.
Yes, I thought about that. There's not much difference between having
configure create the file and having configure substitute the value into
share-subdirs.lisp.in (a new file just for that purpose). Your
approach is slightly simpler to implement, but now requires that we
always remember to install that file. (See my other message about
having the machine create the list of share files to be installed.) My
approach is slightly more complicated, but doesn't have the issue of
remembering to install.
Ray