Standard self upgrade does not work on Clasp
The standard instructions to perform an ASDF self-upgrade do not work on Clasp. If you put asdf.asd somewhere ASDF can find it, the standard
(upgrade-asdf) (called as part of any operation) does not upgrade ASDF. This was not caught earlier because prior to !194 (merged) the upgrade tests only tested basic functionality and did not compare version numbers to ensure the upgrade did what was expected.
The problem seems to be that ASDF is marked as immutable:
clasp -n -N -e '(require :asdf)' -e '(format t "Immutable?: ~S~%" (gethash "asdf" asdf::*immutable-systems*))' Starting cclasp-boehm-0.4.2-3852-gb14e329f4-cst ... loading image... Immutable?: T
Even if this were fixed, we'd probably run into another issue. It seems Clasp actually ships asdf.asd (instead of just the fasls like most other implementations do). And Clasp's
wrapping-source-registry results in their bundled asdf.asd being found and added to the registry.
clasp -n -N -e '(require :asdf)' -e '(asdf:ensure-source-registry)' -e '(format t "asdf in registry: ~S~%" (gethash "asdf" asdf::*source-registry*))' Starting cclasp-boehm-0.4.2-3852-gb14e329f4-cst ... loading image... asdf in registry: #P"SYS:MODULES;ASDF;ASDF.ASD"
This won't affect the tests because they push the asdf.asd under test to the
*central-registry* which overrides the source registry. However, the standard instructions say to drop an updated asdf.asd into ~/common-lisp, which is searched as part of the source registry.
Seems to me we either need to update our manual and say that the only way to update ASDF on Clasp is to
load asdf.lisp, or see if we can get the Clasp maintainers to both not mark ASDF as immutable and make sure the bundled asdf.asd (and likely uiop.asd) either do not go into the source-registry or go at the back of the registry so that users can override it.