;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; This file is part of "NOVA": NOVA = search + COCOMO tools ; Copyright, 2008, Tim Menzies tim@menzies.us ; ; NOVA is free software: you can redistribute it and/or modify ; it under the terms of the GNU General Public License as published by ; the Free Software Foundation, either version 3 of the License, or ; (at your option) any later version. ; ; NOVA is distributed in the hope that it will be useful, ; but WITHOUT ANY WARRANTY; without even the implied warranty of ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ; GNU General Public License for more details. ; You should have received a copy of the GNU General Public License ; a long with NOVA. If not, see . ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; #+SBCL (DECLAIM (SB-EXT:MUFFLE-CONDITIONS CL:STYLE-WARNING)) (let ((what "NOVA v1.0") (when 2008) (who "Tim Menzies") (email "tim@menzies.us") (files '(tricks/eg tricks/lib tricks/macros guess/guess-db config guess/guess xomo/coc-lib xomo/model-defaults xomo/effort-model xomo/months-model xomo/defects-model xomo/threat-model xomo/energy xomo/search-lib apps/a-star apps/beam apps/isamp apps/keys apps/maxwalksat apps/sa apps/seesaw apps/seesaw2 apps/case-studies apps/strategies apps/results apps/convergence apps/hoh-in misc/demos))) (defun make () (maker :files files)) (defun about () (about-string what when who email)) (defun copyright () (gpl3-string what when who email)) (defun version () (format nil "~a. Copyright ~a." what when)) (defun hello () (labels ((line () (terpri) (dotimes (i 50) (princ "-")) (terpri))) (line) (format t "Welcome to ~a~%" (about)) (line)))) (defun maker (&key files faslp forcep) "Loads (after possibly compiling) the given files. If faslp, compiles and loads files. Otherwise, just loads files. If forcep, forces recompilation." (labels ((filename (x y) (string-downcase (format nil "~a.~a" x y))) (src (f) (filename f "lisp")) (bin (f) (filename f "fasl")) (newerp (f1 f2) (> (file-write-date f1) (file-write-date f2))) (compile? (src bin) (or forcep (not (probe-file bin)) (newerp src bin))) (update (f) (if (compile? (src f) (bin f)) (compile-file (src f)))) (cake (f) (update f) (load (bin f))) (loader (f) (format t "; FILE: ~a~%" f) (load f)) (make1 (f) (if faslp (cake f) (loader (src f))))) (mapc #'make1 files))) ;; startup actions (make) (hello)