Skip to content
Snippets Groups Projects
Commit 31d90097 authored by Francois-Rene Rideau's avatar Francois-Rene Rideau
Browse files

2.26.79: restore breaking in the upgrade protocol.

I had failed to preserve the extension point cleanup-upgraded-asdf,
reusing the name the wrong way. Doing it right this time.
parent e2b62423
No related branches found
No related tags found
No related merge requests found
......@@ -15,14 +15,18 @@
:licence "MIT"
:description "Another System Definition Facility"
:long-description "ASDF builds Common Lisp software organized into defined systems."
:version "2.26.78" ;; to be automatically updated by bin/bump-revision
:version "2.26.79" ;; to be automatically updated by bin/bump-revision
:depends-on ()
:components ((:module "build" :components ((:file "asdf")))))
:components ((:module "build" :components ((:file "asdf"))))
:in-order-to (#+asdf2.27 (compile-op (monolithic-load-concatenated-source-op generate-asdf))))
#-asdf2.27
(defmethod perform :before
((o compile-op)
(c (eql (first (module-components
(first (module-components (find-system :asdf))))))))
(declare (ignorable o c))
#-asdf2.27 (perform (make-instance 'load-source-op) c)
#+asdf2.27 (perform (make-instance 'monolithic-load-concatenated-source-op) (find-system 'generate-asdf)))
(declare (ignorable o))
(perform (make-instance 'load-source-op) c))
#+(and clisp (not asdf2.27))
(rename-package :asdf :asdf-utilities)
;; -*- mode: Common-Lisp; Base: 10 ; Syntax: ANSI-Common-Lisp ; coding: utf-8 -*-
;;; This is ASDF 2.26.78: Another System Definition Facility.
;;; This is ASDF 2.26.79: Another System Definition Facility.
;;;
;;; Feedback, bug reports, and patches are all welcome:
;;; please mail to <asdf-devel@common-lisp.net>.
......
......@@ -2,7 +2,7 @@
;;;; Handle ASDF package upgrade, including implementation-dependent magic.
(asdf/package:define-package :asdf/interface
(:nicknames :asdf)
(:nicknames :asdf :asdf-utilities)
(:recycle :asdf/interface :asdf)
(:unintern
#:*asdf-revision* #:around #:asdf-method-combination #:intern*
......
......@@ -3,7 +3,7 @@
(asdf/package:define-package :asdf/operate
(:recycle :asdf/operate :asdf)
(:use :common-lisp :asdf/utility :asdf/upgrade
(:use :common-lisp :asdf/package :asdf/utility :asdf/upgrade
:asdf/component :asdf/system :asdf/operation :asdf/action
:asdf/lisp-build :asdf/lisp-action #:asdf/plan
:asdf/find-system :asdf/find-component)
......@@ -17,12 +17,12 @@
(defgeneric* operate (operation-class system &key &allow-other-keys))
(defun* cleanup-upgraded-asdf ()
(let ((asdf (funcall (find-symbol* 'find-system :asdf) :asdf)))
(defun* reset-asdf-systems ()
(let ((asdf (symbol-call :asdf 'find-system :asdf)))
;; Invalidate all systems but ASDF itself.
(setf *defined-systems* (make-defined-systems-table))
(register-system asdf)
(funcall (find-symbol* 'load-system :asdf) :asdf))) ;; load ASDF a second time, the right way.
(symbol-call :asdf 'load-system :asdf))) ;; load ASDF a second time, the right way.
(defun* restart-upgraded-asdf ()
;; If we're in the middle of something, restart it.
......@@ -31,7 +31,7 @@
(clrhash *systems-being-defined*)
(dolist (s l) (find-system s nil)))))
(pushnew 'cleanup-upgraded-asdf *post-upgrade-cleanup-hook*)
(pushnew 'reset-asdf-systems *post-upgrade-cleanup-hook*)
(pushnew 'restart-upgraded-asdf *post-upgrade-restart-hook*)
......
......@@ -442,5 +442,6 @@ or when loading the package is optional."
#+clisp
(eval-when (:compile-toplevel :load-toplevel :execute)
(when (find-package :asdf) (delete-package* :asdf)))
(when (and (find-package :asdf) (not (member :asdf2.27 *features*)))
(delete-package* :asdf)))
......@@ -167,7 +167,7 @@ case "$lisp" in
eval="-eval" ;;
sbcl)
command="${SBCL:-sbcl}"
flags="--noinform --userinit /dev/null --sysinit /dev/null"
flags="--noinform --userinit /dev/null --sysinit /dev/null" # --eval (require'asdf)
nodebug="--disable-debugger"
eval="--eval" ;;
scl)
......
......@@ -7,7 +7,7 @@
(:use :common-lisp :asdf/package :asdf/compatibility :asdf/utility)
(:export
#:upgrade-asdf #:asdf-upgrade-error #:when-upgrade
#:*post-upgrade-cleanup-hook* #:*post-upgrade-restart-hook*
#:*post-upgrade-cleanup-hook* #:*post-upgrade-restart-hook* #:cleanup-upgraded-asdf
#:asdf-version #:*upgraded-p*
#:asdf-message #:*asdf-verbose* #:*verbose-out*))
(in-package :asdf/upgrade)
......@@ -21,7 +21,7 @@
(defvar *verbose-out* nil)
(defun asdf-message (format-string &rest format-args)
(apply 'format *verbose-out* format-string format-args)))
(eval-when (:load-toplevel :compile-toplevel :execute)
(let* (;; For bug reporting sanity, please always bump this version when you modify this file.
;; Please also modify asdf.asd to reflect this change. The script bin/bump-version
......@@ -31,7 +31,7 @@
;; "2.345.6" would be a development version in the official upstream
;; "2.345.0.7" would be your seventh local modification of official release 2.345
;; "2.345.6.7" would be your seventh local modification of development version 2.345.6
(asdf-version "2.26.78")
(asdf-version "2.26.79")
(existing-asdf (find-class (find-symbol* :component :asdf nil) nil))
(existing-version *asdf-version*)
(already-there (equal asdf-version existing-version)))
......@@ -70,7 +70,7 @@ You can compare this string with e.g.:
(defvar *post-upgrade-cleanup-hook* ())
(defvar *post-upgrade-restart-hook* ())
(defun* post-upgrade-cleanup (old-version)
(defun* cleanup-upgraded-asdf (old-version)
(let ((new-version (asdf-version)))
(unless (equal old-version new-version)
(cond
......@@ -94,6 +94,6 @@ You can compare this string with e.g.:
We need do that before we operate on anything that depends on ASDF."
(let ((version (asdf-version)))
(handler-bind (((or style-warning warning) #'muffle-warning))
(funcall (find-symbol* 'load-system :asdf) :asdf :verbose nil))
(post-upgrade-cleanup version)))
(symbol-call :asdf :load-system :asdf :verbose nil))
(cleanup-upgraded-asdf version)))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment