[asdf-devel] dependency bug?

Tobias C. Rittweiler tcr at freebits.de
Sat Jan 23 09:19:52 UTC 2010


Robert Brown <robert.brown at gmail.com>
writes:

> ASDF is behaving in a way I find mysterious.  Maybe I've found a
> bug, but more likely I just don't understand ASDF dependencies.
>
> To demonstrate the problem, create the three files below.
>
> ==========
> bug.asd
> ==========
>
>     (cl:in-package #:common-lisp-user)
>
>     (defpackage #:bug-system
>       (:use #:common-lisp #:asdf))
>
>     (in-package #:bug-system)
>
>     (defsystem bug
>       :components
>       ((:cl-source-file "bug1")
>        (:cl-source-file "bug2"
>         :in-order-to ((load-op (load-op "bug1"))
>                       (compile-op (load-op "bug1"))))))

If I understand correctly what you want to achieve (that "bug1.lisp" is
compiled and loaded before "bug2.lisp"), then this is usually
done by

  (defsystem bug
    :components
    ((:file "bug1")
     (:file "bug2" :depends-on ("bug1"))))

Or alternatively,

  (defsystem bug
    :serial t     ; sequential dependency graph along textual order
    :components
    ((:file "bug1")
     (:file "bug2")))

(s/:file/:cl-source-file/g if you want so but that distinction is
usually not needed.)

  -T.





More information about the asdf-devel mailing list