From: Dennis Dunn
Subject: Need help with asdf defsystem
Date: 
Message-ID: <pan.2006.02.06.04.10.13.828497@insight.rr.com>
Hello,

I am trying to write an asdf system definition that is dependent upon
other asdf systems being loaded.  The following works but I am wondering
if there isn't a better way of doing this.  I thought of using the #-
reader macro to evaluate the two asdf forms based on items in *features*
or maybe wrapping them in an eval-when.  I also thought that maybe the
:system keyword was what I needed but my understanding there is seriously
lacking.


(asdf:oos 'asdf:load-op :clsql)
(asdf:oos 'asdf:load-op :clsql-postgresql)

(defsystem "camc"
	:serial t
	:components ((:file "packages")
		     (:file "data-layer")
		     (:file "stemmer")))

Even though what I have works, it doesn't say that camc depends on clsql
and clsql-postgresql being already loaded.  Any help there will be
appreciated.

Thanks,

--dennis

ps.  I'm using sbcl 0.9.2 and its included asdf under Ubuntu Linux 5.10.
clsql was downloaded from b9.com.

From: Peter Seibel
Subject: Re: Need help with asdf defsystem
Date: 
Message-ID: <m27j899jb8.fsf@gigamonkeys.com>
Dennis Dunn <·····@insight.rr.com> writes:

> Hello,
>
> I am trying to write an asdf system definition that is dependent upon
> other asdf systems being loaded.  The following works but I am wondering
> if there isn't a better way of doing this.  I thought of using the #-
> reader macro to evaluate the two asdf forms based on items in *features*
> or maybe wrapping them in an eval-when.  I also thought that maybe the
> :system keyword was what I needed but my understanding there is seriously
> lacking.
>
>
> (asdf:oos 'asdf:load-op :clsql)
> (asdf:oos 'asdf:load-op :clsql-postgresql)
>
> (defsystem "camc"
> 	:serial t
> 	:components ((:file "packages")
> 		     (:file "data-layer")
> 		     (:file "stemmer")))
>
> Even though what I have works, it doesn't say that camc depends on clsql
> and clsql-postgresql being already loaded.  Any help there will be
> appreciated.

How about something like:

  (defsystem camc
    :components
    ((:file "packages")
     (:file "data-layer" :depends-on "packages")
     (:file "stemmer"    :depends-on "packages"))
    :depends-on (:clsql :clsql-postgresql))

-Peter

-- 
Peter Seibel           * ·····@gigamonkeys.com
Gigamonkeys Consulting * http://www.gigamonkeys.com/
Practical Common Lisp  * http://www.gigamonkeys.com/book/
From: Dennis Dunn
Subject: Re: Need help with asdf defsystem
Date: 
Message-ID: <pan.2006.02.07.02.46.56.387399@insight.rr.com>
Thanks Peter, that has got to be one of the gentlest applications of the
cluestick in the history of Usenet. :)

> How about something like:
> 
>   (defsystem camc
>     :components
>     ((:file "packages")
>      (:file "data-layer" :depends-on "packages")
>      (:file "stemmer"    :depends-on "packages"))
>     :depends-on (:clsql :clsql-postgresq)))
> 
> -Peter


Of course, that is exactly what I was looking for but couldn't find in
the manual.  I even looked at the "defsystem grammar" page but I never
recognized :depends-on.

Thanks for your help.

--dennis