From: Giannandrea Castaldi
Subject: load cl files with relative filename
Date: 
Message-ID: <bf6e92$gud$1@lacerta.tiscalinet.it>
I've just finished to build xmlutils for parsing html 
(http://opensource.franz.com/xmlutils/index.html).
There is a strange aspect that I don't understand: the first thing I 
have done is try to load the file build.cl:
(load "C:/store/lisp/xmlutils/xmlutils/build.cl")
; Loading C:\store\lisp\xmlutils\xmlutils\build.cl
Error: File #p"pxml0.cl" does not exist.
[condition type: FILE-ERROR]
The problem is that such a file intenally load other files specifying a 
relative path (es.: (load "pxml0.cl")).
I've changed the working directory with the function chdir to 
C:\store\lisp\xmlutils\xmlutils and then tried to load the file build.cl 
specifying a relative path ("build.cl", "./build.cl") but it doesn't 
work. Finally I changed in build.cl
all the references to other .cl file in absolulte path and it now works 
but I don't think this is the right way.
How can I load a cl file with relative references to other files?

Thanks.

Giannandrea
From: Barry Margolin
Subject: Re: load cl files with relative filename
Date: 
Message-ID: <nuzRa.243$0z4.65@news.level3.com>
In article <············@lacerta.tiscalinet.it>,
Giannandrea Castaldi  <········@tiscali.it> wrote:
>How can I load a cl file with relative references to other files?

(let ((*default-pathname-defaults* *load-pathname*))
  (load ...)
  (load ...)
  (load ...))

-- 
Barry Margolin, ··············@level3.com
Level(3), Woburn, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.