[asdf-devel] Cache? Translations? How to get rid of them?

Faré fahree at gmail.com
Sat Mar 13 15:40:50 UTC 2010


Dear Juanjo,

>> I must admit that after four hours fighting with this I am right now a bit
>> pissed off, so please forgive the tone of the message.
>>
I apologize for the complications.

>> ASDF has introduced a new caching system which alters the names of all
>> output files. This is making me mad because I am trying to implement
>> pre-built ASDF components for ECL  and ASDF insists on changing the value of
>> output-files and input-files, looking for those prebuilt files at the
>> location of the cache.
>>
> I forgot to say this is 1.604 That seems to be one source of problems:
> logical pathnames are only kept untouched in recent versions and . However,
> recent versions of ASDF do not work with ECL because a generic function has
> been removed, component-relative-pathname. I attach a diff of the required
> changes.
>
Oops. I suppose it is best to upgrade. In 1.633 we indeed don't apply
translations to logical pathnames (LPNs), since whoever uses LPNs probably
instead want his own LPN translations to take precedence.
I merged your diff to asdf-ecl.lisp into 1.634. I'm sorry I didn't test
and find the bug earlier. I would be wonderful if you contributed a
test script to the test suite so I'd find breakages earlier.

> In any case I still find it problematic that all physical pathnames are
> translated and that no simple way of keeping ECL's system directory untouch
> remains. I tried with
>
>    #+ecl (,(translate-logical-pathname "SYS:") ())
>
> but the resulting initialization is
>
>> (asdf::initialize-output-translations)
>
> (#P"/Users/jjgarcia/lib/ecl-10.3.1/" #P"/Users/jjgarcia/lib/ecl-10.3.1/")
>
> so that the system directory pathname NEVER matches any translation. The
> previous list should instead read
>
> (#P"/Users/jjgarcia/lib/ecl-10.3.1/**/*.*"
> #P"/Users/jjgarcia/lib/ecl-10.3.1/**/*.*")
>
You hit another corner case!
To allow the user to specify arbitrary translations,
not just ones with **/*.* at the end,
we don't add **/*.* to specified pathnames,
only to string-designated pathnames.
Thus, what you wanted was:

>    #+ecl (,(translate-logical-pathname "SYS:**;*.*") ())

It's also what I committed to 1.634.

(This was documented in the manual, but
it's a small note in a big manual indeed.)

PS: if you're going to have some magic ECL-provided ASDF systems
that are tied to the implementation, you should probably want to:

A- add to asdf.lisp's wrapping-source-registry something like:
  #+ecl (:tree ,(translate-logical-pathname "SYS:magic-systems;"))
  This takes precedence over any user-supplied configuration.
  SBCL uses it for its internal magic systems.
B- make sure you do *NOT* provide asdf.asd in *that* directory,
  since combined with the above, that would prevent users
  from installing their own asdf upgrade by taking precedence.
C- if you want to bundle systems that are not too tied to ECL internals,
  you may want to add to default-source-registry something like:
  #+ecl (:tree ,(translate-logical-pathname "SYS:bundled-systems;"))
  There is no problem with providing asdf.asd there, though it's probably
  redundant with the magic from (require :asdf).

The horror! The horror!

[ François-René ÐVB Rideau | Reflection&Cybernethics | http://fare.tunes.org ]
There exist two ways to get rich: the way of economics, that of industrialists,
workers and tradesmen, that consists in freely exchanging the fruits of one's
labor; and the way of politics, that of robbers, bureaucrats and politicians,
that consists in grabbing by force the fruits of the labor of others.




More information about the asdf-devel mailing list