I was using this: (setf (logical-pathname-translations "home") (list (list "**;*.*.*" "/Users/rpg/**/*.*")))
Gives me portability across Mac (/Users) and Linux (/home).
and doing (push "home:lisp;asdf;" asdf:*central-registry*) (asdf:load-system "asdf")
viz:
CL-USER> (logical-pathname-translations "home") ((#P"home:**;*.*.*" #P"/Users/rpg/**/*.*")) CL-USER> (push "home:lisp;asdf;" asdf:*central-registry*) ("home:lisp;asdf;" #P"/Users/rpg/lisp/xophe-clx/" "~/lisp/asdf-systems/" "~/lisp/asdf-install-systems/systems/" "~/lisp/asdf-systems/" "~/lisp/asdf-install-systems/systems/") CL-USER> (asdf:load-system "asdf")
Unfortunately, on my copy of SLIME, attempts to inspect this "illegal logical pathname" object crashes the inspector.
I couldn't reproduce, and I don't fully understand this bug yet, but the crux is that we're somehow trying to parse a physical namestring in the context of either an explicit default or the *default-pathname-defaults* being a logical-pathname, and that's something that causes the bug.
Are you perchance using (setf *resolve-symlinks* nil) ?
I have worked around the same bug in the past, and but maybe it resurfaced despite our testing test-logical-pathname.script.
My understanding is that somehow at some unexpected point your *default-pathname-defaults* is a logical-pathname, and this causes confusion — even #p"" will then be a logical pathname. It could also be that ASDF itself was compiled while *default-pathname-defaults* was a logical pathname, and that #p"" and/or other constants in there are then parsed as logical pathnames, and fail. Or it could be anything.
I think we need a function sane-physical-pathname that takes anything in input, tries to turn it to a physical pathname, then tries with *default-pathname-defaults*, then tries with (user-homedir-pathname), maybe with (lisp-implementation-directory), and finally fails with prejudice. Then, we should wrap a lot of defaulting and all our binding of *default-pathname-defaults* with it.
Logical-pathnames are really a big can of worms and of fail.
Alan Perlis quipped that "A programming language is low level when its programs require attention to the irrelevant." But if instead of requiring attention to irrelevant low-level details, a language requires your attention on gratuitous bogosity, what do you call it?
Until we diagnose the exact issue and fix it, a workaround to achieve what you want without logical pathnames is to use :home for your physical home directory in the location DSL, e.g. your ~/.config/common-lisp/source-registry.conf you read:
(:source-registry (:directory (:home "lisp" "asdf")) (:tree (:home "work" "cl")) :inherit-configuration)
Or you could export CL_SOURCE_REGISTRY='(:source-registry ...)'
Regards,
—♯ƒ • François-René ÐVB Rideau •Reflection&Cybernethics• http://fare.tunes.org I'd rather write programs that write programs than write programs — Dick Sites