colon-separated test file.
[CommonLispStat.git] / lispstat.asd
blobf2e4734d69d12cf4946bc602b890595d2ecd6494
1 ;;  -*- mode: lisp -*-
2 ;;; Time-stamp: <2009-02-19 17:53:25 tony>
3 ;;; Created:    <2005-05-30 17:09:47 blindglobe>
4 ;;; File:       lispstat.asd
5 ;;; Author:     AJ Rossini <blindglobe@gmail.com>
6 ;;; Copyright:  (c) 2005--2008, by AJ Rossini <blindglobe@gmail.com>
7 ;;; License:    BSD, see the top level directory file LICENSE for details.
8 ;;; Purpose:    ASDF packaging for CommonLisp Stat
10 ;;; What is this talk of 'release'? Klingons do not make software
11 ;;; 'releases'.  Our software 'escapes', leaving a bloody trail of
12 ;;; designers and quality assurance people in its wake.
14 (in-package :cl-user)
16 (defpackage :lisp-stat-config
17   (:use :common-lisp)
18   (:export *default-path*
19            *lsos-files* *basic-files* *ls-files*
20            *lispstat-home-dir*
21            *lispstat-data-dir* *lispstat-examples-dir*))
23 (in-package :lisp-stat-config)
25 (defparameter *lispstat-home-dir*
26   (directory-namestring
27    (truename (asdf:system-definition-pathname :lispstat)))
28   "Value considered \"home\" for our data")
31   (setf *lispstat-home-dir*
32       (directory-namestring (truename (asdf:system-definition-pathname
33                                        :lispstat))))
36 (macrolet ((ls-dir (root-str)
37              `(pathname (concatenate 'string
38                                      (namestring *lispstat-home-dir*) ,root-str)))
40            (ls-defdir (target-dir-var  root-str)
41              `(defvar ,target-dir-var (ls-dir ,root-str))))
43   ;; reminder of testing
44   ;;(macroexpand '(ls-defdir *lispstat-asdf-dir* "ASDF"))
45   ;;(macroexpand-1 '(ls-defdir *lispstat-asdf-dir* "ASDF"))
46   ;;(macroexpand-1 '(ls-dir "ASDF"))
48   (ls-defdir *lispstat-asdf-dir* "ASDF/")
49   (ls-defdir *lispstat-data-dir* "Data/")
50   (ls-defdir *lispstat-external-dir* "external/")
53 ;;(pushnew *lispstat-asdf-dir* asdf:*central-registry*)
56 ;; (pushnew #p"C:/Lisp/libs/" asdf-util:*source-dirs* :test #'equal) ; eg for Microsoft
58 ;;; back to our regularly scheduled work...
59 ;;; We should not need these, I think, but?
60 ;; (asdf:oos 'asdf:compile-op :cffi)            ;; FFI
61 ;; (asdf:oos 'asdf:compile-op :lift)            ;; Unit Testing 
62 ;; (asdf:oos 'asdf:load-op :cffi)            ;; FFI
63 ;; (asdf:oos 'asdf:load-op :lift)            ;; Unit Testing 
65 ;;; MAJOR HACK, FIXME!
66 ;;(load "/media/disk/Desktop/sandbox/matlisp.git/start.lisp")
68 (in-package :cl-user)
70 (defpackage #:lispstat-system
71     (:use :common-lisp :asdf))
73 (in-package #:lispstat-system)
75 ;;; To avoid renaming everything from *.lsp to *.lisp...
76 ;;; borrowed from Cyrus Harmon's work, for example for the ch-util.
77 ;;; NOT secure against serving multiple architectures/hardwares from
78 ;;; the same file system (i.e. PPC and x86 would not be
79 ;;; differentiated). 
81 (defclass lispstat-lsp-source-file (cl-source-file) ())
82 (defparameter *fasl-directory*
83    (make-pathname :directory '(:relative
84                                #+sbcl "sbcl-fasl"
85                                #+openmcl "openmcl-fasl"
86                                #+cmu "cmucl-fasl"
87                                #+clisp "clisp-fasl"
88                                #-(or sbcl openmcl clisp cmucl) "fasl"
89                                )))
92 ;;; Handle Luke's *.lsp suffix
93 (defmethod source-file-type ((c lispstat-lsp-source-file) (s module)) "lsp")
94 (defmethod asdf::output-files :around ((operation compile-op)
95                                        (c lispstat-lsp-source-file))
96   (list (merge-pathnames *fasl-directory*
97                          (compile-file-pathname (component-pathname c)))))
98 ;;; again, thanks to Cyrus for saving me time...
101 (defsystem "lispstat"
102   :version #.(with-open-file
103                  (vers (merge-pathnames "version.lisp-expr" *load-truename*))
104                (read vers))
105   :author "A.J. Rossini <blindglobe@gmail.com>"
106   :license "BSD"
107   :description "CommonLispStat (CLS): A System for Statistical
108   Computing with Common Lisp; based on CLS alpha1 by Luke Tierney
109   <luke@stat.uiowa.edu> (apparently originally written when Luke was
110   at CMU, on leave somewhere?).   Last touched by him in 1991, then in
111   2005--2009." 
112   :serial t
113   :depends-on (:cffi :lisp-matrix :lift)
114   :components ((:static-file "version" :pathname #p"version.lisp-expr")
115                (:static-file "LICENSE")
116                (:static-file "README")
117                
118                (:module "packaging"
119                         :pathname #p"src/"
120                         :components
121                         ((:file "packages")))
123                (:module "proto-objects"
124                         :pathname "src/objsys/"
125                         :serial t
126                         :depends-on ("packaging")
127                         :components
128                         ((:lispstat-lsp-source-file "lsobjects")))
130                (:module "lispstat-core"
131                         :pathname "src/basics/"
132                         :serial t
133                         :depends-on ("packaging" "proto-objects")
134                         :components
135                         (; (:lispstat-lsp-source-file "defsys")
136                          (:lispstat-lsp-source-file "lstypes")
137                          (:lispstat-lsp-source-file "lsfloat")
138                          
139                          (:lispstat-lsp-source-file "compound")
140                          (:lispstat-lsp-source-file "lsmacros" 
141                                                     :depends-on ("compound"))
142                          
143                          (:lispstat-lsp-source-file "lsmath"
144                                                     :depends-on ("compound"
145                                                                  "lsmacros"
146                                                                  "lsfloat"))))
148                (:module
149                 "numerics-internal"
150                 :pathname "src/numerics/"
151                 :depends-on ("packaging" "proto-objects" "lispstat-core")
152                 :components
153                 ((:lispstat-lsp-source-file "cffiglue")
154                  (:lispstat-lsp-source-file "dists"
155                                             :depends-on ("cffiglue"))
157                  (:lispstat-lsp-source-file "matrices"
158                                             :depends-on ("cffiglue"))
159                  (:lispstat-lsp-source-file "ladata"
160                                             :depends-on ("cffiglue"
161                                                          "matrices"))
162                  (:file "linalg"
163                         :depends-on ("cffiglue"
164                                      "matrices"
165                                      "ladata"))
167                  ))
169                ;; reading in DSV files for data access
170                (:module 
171                 "csv-data"
172                 :pathname "src/data/"
173                 :components
174                 ((:file "test-cybertiggyr")
175                  (:file "dsv-cybertiggyr" :depends-on ( "test-cybertiggyr"))))
177                ;; prototype and CLOS approaches.
178                (:module
179                 "stat-data"
180                 :pathname "src/data/"
181                 :depends-on ("packaging"
182                              "proto-objects"
183                              "lispstat-core"
184                              "numerics-internal")
185                 :components
186                 ((:file "data-clos")
187                  (:file "data")))
189                (:module
190                 "lispstat-basics"
191                 :pathname "src/basics/"
192                 :depends-on ("packaging"
193                              "proto-objects"
194                              "lispstat-core"
195                              "numerics-internal"
196                              "stat-data")
197                 :components
198                 ((:lispstat-lsp-source-file "lsbasics")))
201                
202                (:module
203                 "descriptives"
204                 :pathname "src/describe/"
205                 :depends-on ("packaging"
206                              "proto-objects"
207                              "lispstat-core"
208                              "numerics-internal"
209                              "stat-data"
210                              "lispstat-basics")
211                 :components
212                 ((:lispstat-lsp-source-file "statistics")))
214                (:module
215                 "optimization"
216                 :pathname "src/numerics/"
217                 :depends-on ("packaging"
218                              "proto-objects"
219                              "lispstat-core"
220                              "numerics-internal"
221                              "stat-data"
222                              "lispstat-basics")
223                 :components
224                 ((:file "optimize")))
225                  
226                
227                ;; Applications
228                (:module
229                 "stat-models"
230                 :pathname "src/stat-models/"
231                 :depends-on ("packaging"
232                              "proto-objects"
233                              "lispstat-core"
234                              "numerics-internal"
235                              "lispstat-basics"
236                              "descriptives"
237                              "optimization")
238                 :components
239                 ((:file "regression")
240                  ;; (:lispstat-lsp-source-file "nonlin"
241                  ;;       :depends-on ("regression"))
242                  ;; (:lispstat-lsp-source-file "bayes"
243                  ;;       :depends-on ("regression"))
244                  ))
246                ;; Applications
247                (:module
248                 "example-data"
249                 :pathname "Data/"
250                 :depends-on ("packaging"
251                              "proto-objects"
252                              "lispstat-core"
253                              "numerics-internal"
254                              "lispstat-basics"
255                              "descriptives"
256                              "optimization")
257                 :components
258                 ((:file "examples")
259                  (:lispstat-lsp-source-file "absorbtion")
260                  (:lispstat-lsp-source-file "diabetes")
261                  (:lispstat-lsp-source-file "leukemia")
262                  (:lispstat-lsp-source-file "randu")
263                  (:lispstat-lsp-source-file "aircraft")
264                  (:lispstat-lsp-source-file "metabolism")
265                  (:lispstat-lsp-source-file "book")
266                  (:lispstat-lsp-source-file "heating")
267                  (:lispstat-lsp-source-file "oxygen")
268                  (:lispstat-lsp-source-file "stackloss") 
269                  (:lispstat-lsp-source-file "car-prices")
270                  (:lispstat-lsp-source-file "iris")
271                  (:lispstat-lsp-source-file "puromycin")
272                  (:lispstat-lsp-source-file "tutorial")))
274                (:module
275                  "lisp-stat-unittest"
276                 :depends-on  ("packaging" "proto-objects"
277                               "lispstat-core"
278                               "numerics-internal" 
279                               "stat-data"
280                               "lispstat-basics"
281                               "descriptives"
282                               "optimization"
283                               "stat-models"
284                               "example-data")
285                  :pathname "src/unittests/"
286                  :components ((:file "unittests")
287                               (:file "unittests-lstypes" :depends-on ("unittests"))
288                               (:file "unittests-specfn" :depends-on ("unittests"))
289                               (:file "unittests-prob" :depends-on ("unittests"))
290                               (:file "unittests-proto" :depends-on ("unittests"))
291                               (:file "unittests-regression" :depends-on ("unittests"))
292                               ;; not ready yet:
293                               ;; (:file "unittests-data-clos" :depends-on ("unittests"))
294                               ;; changing linear algebra system
295                               ;; (:file "unittests-arrays" :depends-on ("unittests"))
296                               ))))