On Fri, 22 Oct 2004 21:02:12 +0200, "Pascal J.Bourguignon" pjb@informatimago.com said:
Pascal> Content-Language: en
Pascal> Martin Simmons writes:
> On Fri, 22 Oct 2004 05:11:27 +0200 (CEST), "Pascal J.Bourguignon" pjb@informatimago.com said:
Pascal> Some lisp implementation can be run on different architectures.
Pascal> If users keep the same home on different computers this will lead to Pascal> collision in ~/.slime/fasl/* directories.
Pascal> To generate the directory name for fasl files, I use the following Pascal> function, adding the machine type:
Pascal> (defun first-word (text) Pascal> (let ((pos (position (character " ") text))) Pascal> (if pos (subseq text 0 pos) text)))
Pascal> (defun implementation-id () Pascal> (format nil "~A-~A-~A" Pascal> (first-word (lisp-implementation-type)) Pascal> (first-word (lisp-implementation-version)) Pascal> (first-word (machine-type))));;implementation-id
This could be problematic if any of the functions returns a string containing illegal filename characters (e.g. /).
Pascal> We could do further filtering, or once such an implementation is Pascal> identified, we could map the values it returns to sane words.
I see that the #+cmu code does that already.
__Martin