Commit c1a125bb authored by Francois-Rene Rideau's avatar Francois-Rene Rideau

Rename asdf/cache to asdf/session

parent a40b94e4
...@@ -80,7 +80,7 @@ XCL ?= xcl ...@@ -80,7 +80,7 @@ XCL ?= xcl
header_lisp := header.lisp header_lisp := header.lisp
driver_lisp := uiop/package.lisp uiop/common-lisp.lisp uiop/utility.lisp uiop/version.lisp uiop/os.lisp uiop/pathname.lisp uiop/filesystem.lisp uiop/stream.lisp uiop/image.lisp uiop/lisp-build.lisp uiop/launch-program.lisp uiop/run-program.lisp uiop/configuration.lisp uiop/backward-driver.lisp uiop/driver.lisp driver_lisp := uiop/package.lisp uiop/common-lisp.lisp uiop/utility.lisp uiop/version.lisp uiop/os.lisp uiop/pathname.lisp uiop/filesystem.lisp uiop/stream.lisp uiop/image.lisp uiop/lisp-build.lisp uiop/launch-program.lisp uiop/run-program.lisp uiop/configuration.lisp uiop/backward-driver.lisp uiop/driver.lisp
defsystem_lisp := upgrade.lisp cache.lisp component.lisp system.lisp find-system.lisp find-component.lisp operation.lisp action.lisp lisp-action.lisp plan.lisp operate.lisp parse-defsystem.lisp bundle.lisp concatenate-source.lisp output-translations.lisp source-registry.lisp package-inferred-system.lisp backward-interface.lisp backward-internals.lisp interface.lisp user.lisp footer.lisp defsystem_lisp := upgrade.lisp session.lisp component.lisp system.lisp find-system.lisp find-component.lisp operation.lisp action.lisp lisp-action.lisp plan.lisp operate.lisp parse-defsystem.lisp bundle.lisp concatenate-source.lisp output-translations.lisp source-registry.lisp package-inferred-system.lisp backward-interface.lisp backward-internals.lisp interface.lisp user.lisp footer.lisp
all_lisp := $(header_lisp) $(driver_lisp) $(defsystem_lisp) all_lisp := $(header_lisp) $(driver_lisp) $(defsystem_lisp)
print-% : ; @echo $* = $($*) print-% : ; @echo $* = $($*)
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
(:nicknames :asdf-action) (:nicknames :asdf-action)
(:recycle :asdf/action :asdf) (:recycle :asdf/action :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade (:use :uiop/common-lisp :uiop :asdf/upgrade
:asdf/component :asdf/system #:asdf/cache :asdf/find-system :asdf/find-component :asdf/operation) :asdf/component :asdf/system #:asdf/session :asdf/find-system :asdf/find-component :asdf/operation)
(:import-from :asdf/operation #:check-operation-constructor) (:import-from :asdf/operation #:check-operation-constructor)
#-clisp (:unintern #:required-components #:traverse-action #:traverse-sub-actions) #-clisp (:unintern #:required-components #:traverse-action #:traverse-sub-actions)
(:export (:export
......
...@@ -44,17 +44,17 @@ ...@@ -44,17 +44,17 @@
:encoding :utf-8 :encoding :utf-8
:components :components
((:file "upgrade") ((:file "upgrade")
(:file "cache" :depends-on ("upgrade")) (:file "session" :depends-on ("upgrade"))
(:file "component" :depends-on ("upgrade")) (:file "component" :depends-on ("upgrade"))
(:file "system" :depends-on ("component")) (:file "system" :depends-on ("component"))
(:file "find-system" :depends-on ("system" "cache")) (:file "find-system" :depends-on ("system" "session"))
(:file "find-component" :depends-on ("find-system")) (:file "find-component" :depends-on ("find-system"))
(:file "operation" :depends-on ("find-system")) (:file "operation" :depends-on ("find-system"))
(:file "action" :depends-on ("find-component" "operation")) (:file "action" :depends-on ("find-component" "operation"))
(:file "lisp-action" :depends-on ("action")) (:file "lisp-action" :depends-on ("action"))
(:file "plan" :depends-on ("lisp-action")) (:file "plan" :depends-on ("lisp-action"))
(:file "operate" :depends-on ("plan")) (:file "operate" :depends-on ("plan"))
(:file "parse-defsystem" :depends-on ("cache" "system" "lisp-action" "operate")) (:file "parse-defsystem" :depends-on ("session" "system" "lisp-action" "operate"))
(:file "bundle" :depends-on ("lisp-action" "operate" "parse-defsystem")) (:file "bundle" :depends-on ("lisp-action" "operate" "parse-defsystem"))
(:file "concatenate-source" :depends-on ("plan" "parse-defsystem" "bundle")) (:file "concatenate-source" :depends-on ("plan" "parse-defsystem" "bundle"))
(:file "output-translations" :depends-on ("operate")) (:file "output-translations" :depends-on ("operate"))
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
(uiop/package:define-package :asdf/find-component (uiop/package:define-package :asdf/find-component
(:recycle :asdf/find-component :asdf) (:recycle :asdf/find-component :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/cache (:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/session
:asdf/component :asdf/system :asdf/find-system) :asdf/component :asdf/system :asdf/find-system)
(:export (:export
#:find-component #:find-component
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
(uiop/package:define-package :asdf/find-system (uiop/package:define-package :asdf/find-system
(:recycle :asdf/find-system :asdf) (:recycle :asdf/find-system :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade (:use :uiop/common-lisp :uiop :asdf/upgrade
:asdf/cache :asdf/component :asdf/system) :asdf/session :asdf/component :asdf/system)
(:export (:export
#:remove-entry-from-registry #:coerce-entry-to-directory #:remove-entry-from-registry #:coerce-entry-to-directory
#:coerce-name #:primary-system-name #:coerce-filename #:coerce-name #:primary-system-name #:coerce-filename
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
(:unintern (:unintern
#:loaded-systems ; makes for annoying SLIME completion #:loaded-systems ; makes for annoying SLIME completion
#:output-files-for-system-and-operation) ; ASDF-BINARY-LOCATION function we use to detect ABL #:output-files-for-system-and-operation) ; ASDF-BINARY-LOCATION function we use to detect ABL
(:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/cache (:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/session
:asdf/component :asdf/system :asdf/find-system :asdf/find-component :asdf/component :asdf/system :asdf/find-system :asdf/find-component
:asdf/operation :asdf/action :asdf/lisp-action :asdf/operation :asdf/action :asdf/lisp-action
:asdf/output-translations :asdf/source-registry :asdf/output-translations :asdf/source-registry
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
(uiop/package:define-package :asdf/lisp-action (uiop/package:define-package :asdf/lisp-action
(:recycle :asdf/lisp-action :asdf) (:recycle :asdf/lisp-action :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/cache (:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/session
:asdf/component :asdf/system :asdf/find-component :asdf/find-system :asdf/component :asdf/system :asdf/find-component :asdf/find-system
:asdf/operation :asdf/action) :asdf/operation :asdf/action)
(:export (:export
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
set here=%~dp0 set here=%~dp0
set header_lisp=header.lisp set header_lisp=header.lisp
set driver_lisp=uiop\package.lisp + uiop\common-lisp.lisp + uiop\utility.lisp + uiop\version.lisp + uiop\os.lisp + uiop\pathname.lisp + uiop\filesystem.lisp + uiop\stream.lisp + uiop\image.lisp + uiop\lisp-build.lisp + uiop\launch-program.lisp + uiop\run-program.lisp + uiop\configuration.lisp + uiop\backward-driver.lisp + uiop\driver.lisp set driver_lisp=uiop\package.lisp + uiop\common-lisp.lisp + uiop\utility.lisp + uiop\version.lisp + uiop\os.lisp + uiop\pathname.lisp + uiop\filesystem.lisp + uiop\stream.lisp + uiop\image.lisp + uiop\lisp-build.lisp + uiop\launch-program.lisp + uiop\run-program.lisp + uiop\configuration.lisp + uiop\backward-driver.lisp + uiop\driver.lisp
set defsystem_lisp=upgrade.lisp + cache.lisp + component.lisp + system.lisp + find-system.lisp + find-component.lisp + operation.lisp + action.lisp + lisp-action.lisp + plan.lisp + operate.lisp + parse-defsystem.lisp + bundle.lisp + concatenate-source.lisp + output-translations.lisp + source-registry.lisp + package-inferred-system.lisp + backward-interface.lisp + backward-internals.lisp + interface.lisp + user.lisp + footer.lisp set defsystem_lisp=upgrade.lisp + session.lisp + component.lisp + system.lisp + find-system.lisp + find-component.lisp + operation.lisp + action.lisp + lisp-action.lisp + plan.lisp + operate.lisp + parse-defsystem.lisp + bundle.lisp + concatenate-source.lisp + output-translations.lisp + source-registry.lisp + package-inferred-system.lisp + backward-interface.lisp + backward-internals.lisp + interface.lisp + user.lisp + footer.lisp
%~d0 %~d0
cd "%~p0" cd "%~p0"
......
...@@ -6,7 +6,7 @@ here="$(dirname $0)" ...@@ -6,7 +6,7 @@ here="$(dirname $0)"
header_lisp="header.lisp" header_lisp="header.lisp"
driver_lisp="uiop/package.lisp uiop/common-lisp.lisp uiop/utility.lisp uiop/version.lisp uiop/os.lisp uiop/pathname.lisp uiop/filesystem.lisp uiop/stream.lisp uiop/image.lisp uiop/lisp-build.lisp uiop/launch-program.lisp uiop/run-program.lisp uiop/configuration.lisp uiop/backward-driver.lisp uiop/driver.lisp" driver_lisp="uiop/package.lisp uiop/common-lisp.lisp uiop/utility.lisp uiop/version.lisp uiop/os.lisp uiop/pathname.lisp uiop/filesystem.lisp uiop/stream.lisp uiop/image.lisp uiop/lisp-build.lisp uiop/launch-program.lisp uiop/run-program.lisp uiop/configuration.lisp uiop/backward-driver.lisp uiop/driver.lisp"
defsystem_lisp="upgrade.lisp cache.lisp component.lisp system.lisp find-system.lisp find-component.lisp operation.lisp action.lisp lisp-action.lisp plan.lisp operate.lisp parse-defsystem.lisp bundle.lisp concatenate-source.lisp output-translations.lisp source-registry.lisp package-inferred-system.lisp backward-interface.lisp backward-internals.lisp interface.lisp user.lisp footer.lisp" defsystem_lisp="upgrade.lisp session.lisp component.lisp system.lisp find-system.lisp find-component.lisp operation.lisp action.lisp lisp-action.lisp plan.lisp operate.lisp parse-defsystem.lisp bundle.lisp concatenate-source.lisp output-translations.lisp source-registry.lisp package-inferred-system.lisp backward-interface.lisp backward-internals.lisp interface.lisp user.lisp footer.lisp"
all () { all () {
# Default action: bootstrap asdf.lisp # Default action: bootstrap asdf.lisp
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
(uiop/package:define-package :asdf/operate (uiop/package:define-package :asdf/operate
(:recycle :asdf/operate :asdf) (:recycle :asdf/operate :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/cache (:use :uiop/common-lisp :uiop :asdf/upgrade :asdf/session
:asdf/component :asdf/system :asdf/operation :asdf/action :asdf/component :asdf/system :asdf/operation :asdf/action
:asdf/find-system :asdf/find-component :asdf/lisp-action :asdf/plan) :asdf/find-system :asdf/find-component :asdf/lisp-action :asdf/plan)
(:export (:export
...@@ -86,13 +86,15 @@ But do NOT depend on it, for this is deprecated behavior.")) ...@@ -86,13 +86,15 @@ But do NOT depend on it, for this is deprecated behavior."))
(defmethod operate :before ((operation operation) (component component) (defmethod operate :before ((operation operation) (component component)
&key version &allow-other-keys) &key version &allow-other-keys)
(unless (version-satisfies component version) (unless (version-satisfies component version)
(error 'missing-component-of-version :requires component :version version))) (error 'missing-component-of-version :requires component :version version))
(when *plan*
(plan-record-dependency *plan* operation component)))
(defmethod operate ((operation operation) (component component) (defmethod operate ((operation operation) (component component)
&rest keys &key plan-class &allow-other-keys) &rest keys &key plan-class &allow-other-keys)
(let ((plan (apply 'make-plan plan-class operation component keys))) (let ((*plan* (apply 'make-plan plan-class operation component #|:parent *plan*|# keys)))
(apply 'perform-plan plan keys) (apply 'perform-plan *plan* keys)
(values operation plan))) (values operation *plan*)))
(defun oos (operation component &rest args &key &allow-other-keys) (defun oos (operation component &rest args &key &allow-other-keys)
(apply 'operate operation component args)) (apply 'operate operation component args))
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
(:recycle :asdf/parse-defsystem :asdf/defsystem :asdf) (:recycle :asdf/parse-defsystem :asdf/defsystem :asdf)
(:nicknames :asdf/defsystem) ;; previous name, to be compatible with, in case anyone cares (:nicknames :asdf/defsystem) ;; previous name, to be compatible with, in case anyone cares
(:use :uiop/common-lisp :asdf/driver :asdf/upgrade (:use :uiop/common-lisp :asdf/driver :asdf/upgrade
:asdf/cache :asdf/component :asdf/system :asdf/session :asdf/component :asdf/system
:asdf/find-system :asdf/find-component :asdf/action :asdf/lisp-action :asdf/operate) :asdf/find-system :asdf/find-component :asdf/action :asdf/lisp-action :asdf/operate)
(:import-from :asdf/system #:depends-on #:weakly-depends-on) (:import-from :asdf/system #:depends-on #:weakly-depends-on)
(:export (:export
......
...@@ -7,11 +7,11 @@ ...@@ -7,11 +7,11 @@
(:recycle :asdf/plan :asdf) (:recycle :asdf/plan :asdf)
(:use :uiop/common-lisp :uiop :asdf/upgrade (:use :uiop/common-lisp :uiop :asdf/upgrade
:asdf/component :asdf/operation :asdf/system :asdf/component :asdf/operation :asdf/system
:asdf/cache :asdf/find-system :asdf/find-component :asdf/session :asdf/find-system :asdf/find-component
:asdf/operation :asdf/action :asdf/lisp-action) :asdf/operation :asdf/action :asdf/lisp-action)
(:export (:export
#:component-operation-time #:component-operation-time
#:plan #:plan-traversal #:sequential-plan #:*default-plan-class* #:plan #:plan-traversal #:sequential-plan #:*default-plan-class* #:*plan*
#:planned-action-status #:plan-action-status #:action-already-done-p #:planned-action-status #:plan-action-status #:action-already-done-p
#:circular-dependency #:circular-dependency-actions #:circular-dependency #:circular-dependency-actions
#:needed-in-image-p #:needed-in-image-p
...@@ -55,7 +55,10 @@ ...@@ -55,7 +55,10 @@
(visiting-action-set ;; as a set (visiting-action-set ;; as a set
:initform (make-hash-table :test 'equal) :accessor plan-visiting-action-set) :initform (make-hash-table :test 'equal) :accessor plan-visiting-action-set)
(visiting-action-list :initform () :accessor plan-visiting-action-list)) ;; as a list (visiting-action-list :initform () :accessor plan-visiting-action-list)) ;; as a list
(:documentation "Base class for plans that simply traverse dependencies"))) (:documentation "Base class for plans that simply traverse dependencies"))
(defvar *plan* nil
"The plan currently being executed"))
;;;; Planned action status ;;;; Planned action status
...@@ -467,11 +470,11 @@ initialized with SEED." ...@@ -467,11 +470,11 @@ initialized with SEED."
(apply 'perform-plan (plan-actions plan) keys)) (apply 'perform-plan (plan-actions plan) keys))
(defmethod perform-plan ((steps list) &key force &allow-other-keys) (defmethod perform-plan ((steps list) &key force &allow-other-keys)
(loop* :for action :in steps (loop :for action :in steps
:as o = (action-operation action) :as o = (action-operation action)
:as c = (action-component action) :as c = (action-component action)
:when (or force (not (nth-value 1 (compute-action-stamp nil o c)))) :unless (nth-value 1 (compute-action-stamp nil o c))
:do (perform-with-restarts o c))) :do (perform-with-restarts o c)))
(defmethod plan-operates-on-p ((plan plan-traversal) (component-path list)) (defmethod plan-operates-on-p ((plan plan-traversal) (component-path list))
(plan-operates-on-p (plan-actions plan) component-path)) (plan-operates-on-p (plan-actions plan) component-path))
......
;;;; ------------------------------------------------------------------------- ;;;; -------------------------------------------------------------------------
;;;; Session cache ;;;; Session cache
(uiop/package:define-package :asdf/cache (uiop/package:define-package :asdf/session
(:recycle :asdf/session :asdf/cache)
(:use :uiop/common-lisp :uiop :asdf/upgrade) (:use :uiop/common-lisp :uiop :asdf/upgrade)
(:export #:get-file-stamp #:compute-file-stamp #:register-file-stamp (:export #:get-file-stamp #:compute-file-stamp #:register-file-stamp
#:set-asdf-cache-entry #:unset-asdf-cache-entry #:consult-asdf-cache #:set-asdf-cache-entry #:unset-asdf-cache-entry #:consult-asdf-cache
#:do-asdf-cache #:normalize-namestring #:do-asdf-cache #:normalize-namestring
#:call-with-asdf-cache #:with-asdf-cache #:*asdf-cache* #:call-with-asdf-cache #:with-asdf-cache #:*asdf-cache*
#:clear-configuration-and-retry #:retry)) #:clear-configuration-and-retry #:retry))
(in-package :asdf/cache) (in-package :asdf/session)
;;; The ASDF session cache is used to memoize some computations. It is instrumental in achieving: ;;; The ASDF session cache is used to memoize some computations. It is instrumental in achieving:
;; * Consistency in the view of the world relied on by ASDF within a given session. ;; * Consistency in the view of the world relied on by ASDF within a given session.
......
...@@ -655,7 +655,7 @@ is bound, write a message and exit on an error. If ...@@ -655,7 +655,7 @@ is bound, write a message and exit on an error. If
(format t "Frob packages~%") (format t "Frob packages~%")
(use-package :asdf :asdf-test) (use-package :asdf :asdf-test)
(when (find-package :uiop) (use-package :uiop :asdf-test)) (when (find-package :uiop) (use-package :uiop :asdf-test))
(when (find-package :asdf/cache) (use-package :asdf/cache :asdf-test)) (when (find-package :asdf/session) (use-package :asdf/session :asdf-test))
(setf *package* (find-package :asdf-test)) (setf *package* (find-package :asdf-test))
t) t)
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
`(,*asdf-directory* "build/fasls" :implementation "logical-host-asdf") `(,*asdf-directory* "build/fasls" :implementation "logical-host-asdf")
:wilden t)))) :wilden t))))
(setf asdf/cache:*asdf-cache* nil) (setf asdf/session:*asdf-cache* nil)
(DBG :logical (DBG :logical
(logical-pathname-translations "ASDF") (logical-pathname-translations "ASDF")
......
...@@ -283,7 +283,7 @@ ...@@ -283,7 +283,7 @@
asdf/find-system:contrib-sysdef-search asdf/find-system:contrib-sysdef-search
asdf/find-system:sysdef-find-asdf asdf/find-system:sysdef-find-asdf
;; restart ;; restart
asdf/cache:clear-configuration-and-retry asdf/session:clear-configuration-and-retry
)) ))
(defun defined-symbol-p (symbol) (defun defined-symbol-p (symbol)
......
;;; -*- Lisp -*- ;;; -*- Lisp -*-
(setf asdf/cache:*asdf-cache* nil) ;; disable cache between those two very different compilations. (setf asdf/session:*asdf-cache* nil) ;; disable cache between those two very different compilations.
#-(and ecl ecl-bytecmp) #-(and ecl ecl-bytecmp)
(setf asdf::*load-system-operation* 'load-bundle-op) ;; This triggers a bug on ECL no more! (setf asdf::*load-system-operation* 'load-bundle-op) ;; This triggers a bug on ECL no more!
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment