[Openmcl-devel] Re: Another pathname question

Octav Popescu octav at cmu.edu
Thu Feb 26 13:02:14 PST 2004

One thing that might be problematic is load-pathname. I couldn't find it in 
the hyperspec index, I don't know if it's part of the standard. There is a 
*load-pathname* variable however.

If you're just interested in something that works, this is what I found to 
be working in MCL, Lispworks, and Allegro. I don't know about OpenMCL, I 
haven't tried.

(setf (logical-pathname-translations "foo")
        ,(make-pathname :host (pathname-host *load-truename*)
                        :directory (append (pathname-directory 
                        :name :wild :type :wild))
        ,(make-pathname :host (pathname-host *load-truename*)
                        :directory (append (pathname-directory 
                        :name :wild :type :wild))))

The second definitions was actually needed in one of Lispworks or Allegro, 
I don't remember which one. Or maybe both.

I haven't tried to use *default-pathname-defaults*, I just used (load 
"foo:two"). I don't think it should make a difference.


--On Thursday, February 26, 2004 10:48 -0500 Gary King 
<gwking at cs.umass.edu> wrote:

> I have two files named "one.lisp" and "two.lisp". Here they are:
> one.lisp
> (in-package common-lisp-user)
> (setf (logical-pathname-translations "foo")
>       `(("foo:**;*.*"
>          ,(make-pathname
>            :name :wild
>            :type :wild
>            :directory (append (pathname-directory (load-pathname))
>                               (list :wild-inferiors))))))
> (let ((*default-pathname-defaults* #P"foo:"))
>   (load "two"))
> two.lisp
> (in-package common-lisp-user)
> (print "HI HO")
> I've placed them in the same directory. Now my hope was that when I load
> one, it will load two. This works under MCL. It does not, however, work
> under LispWorks, OpenMCL, etc. Under OpenMCL, I get the following error:
> ? (load "one.lisp")
>> Error in process listener(1): Illegal logical namestring
>> "/Volumes/Users/gwking/Applications/MCL-5.1b1/test/two.lisp"  While
> Under LispWorks, I get:
> Error: Parsing of logical pathname "/.automount/*/root/**/*" failed at
> index 0 (#\/).    1 (continue) Try loading two again.
>   ...
> Obviously, I'm confused. Help appreciated.
> --
> Gary Warren King, Lab Manager
> EKSL East, University of Massachusetts * 413 577 0176
> [neoconservations] forget the first principle of open society: namely,
> that we may be wrong.     -- George Soros in a TPM interview
> (http://www.talkingpointsmemo.com/archives/week_2004_01_18.html#002456)

More information about the Openmcl-devel mailing list