[Openmcl-devel] Directory and symlinks

Zach Beane xach at xach.com
Fri Nov 11 10:06:32 PST 2011

Gary Byers <gb at clozure.com> writes:

> On Wed, 9 Nov 2011, Zach Beane wrote:
>> Gary Byers <gb at clozure.com> writes:
>>> I couldn't reproduce this.
>>> If you're calling DIRECTORY with a relative pathname, what's the value of
>>> *DEFAULT-PATHNAME-DEFAULTS* ?  What does calling
>> *default-pathname-defaults* is #p"" and :pwd returns
>> #p"/home/xach/tmp/", the directory in which I created the test directory
>> structure.
>>> If neither of those things explain it:
>>> On a Linux system, my home directory is "/home/gb" and CCL is installed
>>> in "/usr/local/src/ccl". If I do (in the shell):
>>> $ cd
>>> $ ln -sf ../../usr/local/src/ccl .   # also tried absolute name here
>>> and in CCL:
>>> ? :pwd                          ; can also call (CCL:DEFAULT-DERECTORY)
>>> #P"/home/gb/"
>>> ? (directory "ccl/*/*.lx64fsl")
>>> => list of .lx64fsl files in immediate subdirectories of CCL directory.
>>> What's different about what I'm doing and what you're doing ?
>> The symlink in my case is behind the wildcard, perhaps that makes the
>> difference?
> Yes, it seems to.
>> Does (directory "*/*.image") return the /usr/local/src/ccl/*.image files
>> for you?
> No, and there's at least some argument that it shouldn't.  (I'm not absoulutely
> sure that I believe that argument ...)

In light of CCL's interpretation of the standard, can you suggest a
terse way to get a list of all files with a pathname-type of "txt" in a
directory tree rooted at e.g. #p"foo/" where some entries under foo/
might be symlinks to directories outside of foo/? I don't mind using
something implementation-specific if it does the job.


More information about the Openmcl-devel mailing list