From 5e973388c026e0da6b065ed83e3d80251a3487f6 Mon Sep 17 00:00:00 2001 From: Robert Dodier Date: Tue, 5 Jan 2016 10:55:42 -0800 Subject: [PATCH] In COMPUTE-LOAD-STRATEGY, call new function ASDF-FIND-SYSTEM-TRY-HARDER which uses Quicklisp to download systems when ASDF:FIND-SYSTEM fails. This makes it possible to download and install systems named by :defsystem-depends-on. --- quicklisp/setup.lisp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/quicklisp/setup.lisp b/quicklisp/setup.lisp index fb2a671..a34792a 100644 --- a/quicklisp/setup.lisp +++ b/quicklisp/setup.lisp @@ -61,12 +61,19 @@ system given to load is not available via ASDF or a Quicklisp dist.")) +(defun asdf-find-system-try-harder (name) + (handler-bind + ((asdf::load-system-definition-error + #'(lambda (c) (ql:quickload (asdf::missing-requires (asdf::error-condition c))) + (invoke-restart 'asdf::reinitialize-source-registry-and-retry)))) + (asdf:find-system name nil))) + (defun compute-load-strategy (name) (setf name (string-downcase name)) (let ((asdf-systems '()) (quicklisp-systems '())) (labels ((recurse (name) - (let ((asdf-system (asdf:find-system name nil)) + (let ((asdf-system (asdf-find-system-try-harder name)) (quicklisp-system (find-system name))) (cond (asdf-system (push asdf-system asdf-systems))