2 ;;; Time-stamp: <2008-12-19 08:47:22 tony>
3 ;;; Created: <2005-05-30 17:09:47 blindglobe>
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.
16 (defpackage :lisp-stat-config
18 (:export *default-path*
19 *lsos-files* *basic-files* *ls-files*
21 *lispstat-data-dir* *lispstat-examples-dir*))
23 (in-package :lisp-stat-config)
25 (defparameter *lispstat-home-dir*
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
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*)
54 ;; (pushnew #p"C:/Lisp/libs/" asdf-util:*source-dirs* :test #'equal) ; eg for Microsoft
56 ;;; back to our regularly scheduled work...
57 ;;; We should not need these, I think, but?
58 ;; (asdf:oos 'asdf:compile-op :cffi) ;; FFI
59 ;; (asdf:oos 'asdf:compile-op :lift) ;; Unit Testing
60 ;; (asdf:oos 'asdf:load-op :cffi) ;; FFI
61 ;; (asdf:oos 'asdf:load-op :lift) ;; Unit Testing
63 ;;; MAJOR HACK, FIXME!
64 ;;(load "/media/disk/Desktop/sandbox/matlisp.git/start.lisp")
68 (defpackage #:lispstat-system
69 (:use :common-lisp :asdf))
71 (in-package #:lispstat-system)
73 ;;; To avoid renaming everything from *.lsp to *.lisp...
74 ;;; borrowed from Cyrus Harmon's work, for example for the ch-util.
75 ;;; NOT secure against serving multiple architectures/hardwares from
76 ;;; the same file system (i.e. PPC and x86 would not be
79 (defclass lispstat-lsp-source-file (cl-source-file) ())
80 (defparameter *fasl-directory*
81 (make-pathname :directory '(:relative
83 #+openmcl "openmcl-fasl"
86 #-(or sbcl openmcl clisp cmucl) "fasl"
90 ;;; Handle Luke's *.lsp suffix
91 (defmethod source-file-type ((c lispstat-lsp-source-file) (s module)) "lsp")
92 (defmethod asdf::output-files :around ((operation compile-op)
93 (c lispstat-lsp-source-file))
94 (list (merge-pathnames *fasl-directory*
95 (compile-file-pathname (component-pathname c)))))
96 ;;; again, thanks to Cyrus for saving me time...
100 :version #.(with-open-file
101 (vers (merge-pathnames "version.lisp-expr" *load-truename*))
103 :author "A.J. Rossini <blindglobe@gmail.com>"
105 :description "CommonLispStat (CLS): A System for Statistical
106 Computing with Common Lisp; based on CLS alpha1 by Luke Tierney
107 <luke@stat.uiowa.edu> (apparently originally written when Luke was
108 at CMU, on leave somewhere?). Last touched by him in 1991, then in
111 :depends-on (:cffi :lisp-matrix :lift)
112 :components ((:static-file "version" :pathname #p"version.lisp-expr")
113 (:static-file "LICENSE")
114 (:static-file "README")
119 ((:file "packages")))
121 (:module "proto-objects"
122 :pathname "src/objsys/"
124 :depends-on ("packaging")
126 ((:lispstat-lsp-source-file "lsobjects")))
128 (:module "lispstat-core"
129 :pathname "src/basics/"
131 :depends-on ("packaging" "proto-objects")
133 (; (:lispstat-lsp-source-file "defsys")
134 (:lispstat-lsp-source-file "lstypes")
135 (:lispstat-lsp-source-file "lsfloat")
137 (:lispstat-lsp-source-file "compound")
138 (:lispstat-lsp-source-file "lsmacros"
139 :depends-on ("compound"))
141 (:lispstat-lsp-source-file "lsmath"
142 :depends-on ("compound"
148 :pathname "src/numerics/"
149 :depends-on ("packaging" "proto-objects" "lispstat-core")
151 ((:lispstat-lsp-source-file "cffiglue")
152 (:lispstat-lsp-source-file "dists"
153 :depends-on ("cffiglue"))
155 (:lispstat-lsp-source-file "matrices"
156 :depends-on ("cffiglue"))
157 (:lispstat-lsp-source-file "ladata"
158 :depends-on ("cffiglue"
161 :depends-on ("cffiglue"
167 ;; prototype and CLOS approaches.
170 :pathname "src/data/"
171 :depends-on ("packaging"
181 :pathname "src/basics/"
182 :depends-on ("packaging"
188 ((:lispstat-lsp-source-file "lsbasics")))
193 :pathname "src/describe/"
194 :depends-on ("packaging"
201 ((:lispstat-lsp-source-file "statistics")))
205 :pathname "src/numerics/"
206 :depends-on ("packaging"
213 ((:file "optimize")))
219 :pathname "src/stat-models/"
220 :depends-on ("packaging"
228 ((:file "regression")
229 ;; (:lispstat-lsp-source-file "nonlin"
230 ;; :depends-on ("regression"))
231 ;; (:lispstat-lsp-source-file "bayes"
232 ;; :depends-on ("regression"))
239 :depends-on ("packaging"
248 (:lispstat-lsp-source-file "absorbtion")
249 (:lispstat-lsp-source-file "diabetes")
250 (:lispstat-lsp-source-file "leukemia")
251 (:lispstat-lsp-source-file "randu")
252 (:lispstat-lsp-source-file "aircraft")
253 (:lispstat-lsp-source-file "metabolism")
254 (:lispstat-lsp-source-file "book")
255 (:lispstat-lsp-source-file "heating")
256 (:lispstat-lsp-source-file "oxygen")
257 (:lispstat-lsp-source-file "stackloss")
258 (:lispstat-lsp-source-file "car-prices")
259 (:lispstat-lsp-source-file "iris")
260 (:lispstat-lsp-source-file "puromycin")
261 (:lispstat-lsp-source-file "tutorial")))
265 :depends-on ("packaging" "proto-objects"
274 :pathname "src/unittests/"
275 :components ((:file "unittests")
276 (:file "unittests-lstypes" :depends-on ("unittests"))
277 (:file "unittests-specfn" :depends-on ("unittests"))
278 (:file "unittests-prob" :depends-on ("unittests"))
279 (:file "unittests-proto" :depends-on ("unittests"))
280 (:file "unittests-regression" :depends-on ("unittests"))
282 ;; (:file "unittests-data-clos" :depends-on ("unittests"))
283 ;; changing linear algebra system
284 ;; (:file "unittests-arrays" :depends-on ("unittests"))