Skip to content
Snippets Groups Projects
Commit ecbd83d5 authored by Robert Goldman's avatar Robert Goldman
Browse files

Fix for launchpad bug 1445638.

When collecting the defsystem-dependencies in
REGISTER-SYSTEM-DEFINITION, throw away NILs, which correspond to systems
not needed because of :FEATURE checks.

Added test case for bug, too.
parent 5bd63e76
No related branches found
No related tags found
No related merge requests found
...@@ -250,8 +250,9 @@ system names contained using COERCE-NAME. Return the result." ...@@ -250,8 +250,9 @@ system names contained using COERCE-NAME. Return the result."
:name name :source-file source-file)) :name name :source-file source-file))
(component-options (component-options
(remove-plist-keys '(:defsystem-depends-on :class) options)) (remove-plist-keys '(:defsystem-depends-on :class) options))
(defsystem-dependencies (loop :for spec :in defsystem-depends-on :collect (defsystem-dependencies (loop :for spec :in defsystem-depends-on
(resolve-dependency-spec nil spec)))) :when (resolve-dependency-spec nil spec)
:collect :it)))
;; cache defsystem-depends-on in canonical form ;; cache defsystem-depends-on in canonical form
(when defsystem-depends-on (when defsystem-depends-on
(setf component-options (setf component-options
......
;;-*- Lisp -*- ;;-*- Lisp -*-
(in-package :asdf-test)
(def-test-system test-defsystem-depends-on-1 (def-test-system test-defsystem-depends-on-1
:defsystem-depends-on (test-asdf/l-file) :defsystem-depends-on (test-asdf/l-file)
:default-component-class "l-file:cl-source-file.l" :default-component-class "l-file:cl-source-file.l"
...@@ -32,6 +34,7 @@ ...@@ -32,6 +34,7 @@
(defparameter *newsym* (gentemp (symbol-name 'feature) :keyword)) (defparameter *newsym* (gentemp (symbol-name 'feature) :keyword))
;;; FIXME: the following form triggers bug https://bugs.launchpad.net/asdf/+bug/1445638 ;;; FIXME: the following form triggers bug https://bugs.launchpad.net/asdf/+bug/1445638
#+nil
(eval `(def-test-system test-defsystem-depends-on-4 (eval `(def-test-system test-defsystem-depends-on-4
:defsystem-depends-on ((:feature ,*newsym* "test-defsystem-depends-on-3")))) :defsystem-depends-on ((:feature ,*newsym* "test-defsystem-depends-on-3"))))
(assert (find-system "test-defsystem-depends-on-4"))
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