1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123
|
;;; -*- Mode: Lisp -*-
;;; Possible code for inclusion in the Armed Bear startup file
;;; #p"~/.abclrc"
;;; Some commonly useful customizations to ABCL output
(setf
;; Truncate the output of java.lang.String object after this many
;; characters, outputing "...." afterwards.
;; The default is 32. Is this too small?
*java-object-to-string-length* 8192
;; Show what is being loaded and the loading time.
;; Helpful on slower systems to figure out what is taking the time.
*load-verbose* t
;; Emit warnings from debug code
sys:*debug-warn* t
;; Bring some order to the forms output by the REPL
;; Not currently the default, but it probably should be after we
;; rework the pretty printer and/or streams to properly work with
;; GRAY-STREAMS:
*print-pretty* t)
#-quicklisp
(let ((quicklisp-local #P"~/quicklisp/setup.lisp")
(quicklisp-remote #p"http://beta.quicklisp.org/quicklisp.lisp"))
(unless (probe-file quicklisp-local)
(when (probe-file quicklisp-remote) ;;; XXX possibly search for a proxy÷
(load quicklisp-remote)
(funcall (intern (symbol-name 'install) :quicklisp-quickstart))))
(when (probe-file quicklisp-local)
(load quicklisp-local)))
;;
(require :asdf)
(require :abcl-contrib)
(require :abcl-asdf)
(setf abcl-asdf::*maven-http-proxy* "http://localhost:3128/")
;;; Customize the procedure used by CL:DISASSEMBLE
(setf *disassembler*
(let ((strategies (list (lambda (p)
(let ((class (make-pathname :name (pathname-name p)))
(path (directory-namestring p)))
(format nil "javap -c -l -verbose -classpath ~A ~A" path class)))
"/Users/evenson/bin/jad -a -p"
(lambda (p)
(format nil "java -jar ~
/Users/evenson/work/classfileanalyzer/classfileanalyzer.jar ~A"
p)))))
(first strategies)))
(defparameter *ansi-tests-directory*
#-(or windows mswindows win32)
#p"/home/peter/xcl/x/ansi-tests/"
#+(or windows mswindows win32)
#p"c:\\msys\\1.0\\home\\peter\\xcl\\x\ansi-tests\\")
(defun run-ansi-tests (&optional (compile-tests t))
(format t "COMPILE-TESTS is ~A~%" compile-tests)
(let ((*default-pathname-defaults* *ansi-tests-directory*))
#+(and abcl unix)
(run-shell-command "make clean" :directory *default-pathname-defaults*)
(time (load (if compile-tests "compileit.lsp" "doit.lsp")))))
(defun run-random-tests (size nvars count)
(let ((*default-pathname-defaults* *ansi-tests-directory*))
(load "gclload1.lsp")
(load "random-int-form.lsp")
(let ((f (find-symbol "TEST-RANDOM-INTEGER-FORMS" "CL-TEST")))
(when f
(let (#+abcl (*suppress-compiler-warnings* t)
(*random-state* (make-random-state t)))
(time (funcall f size nvars count)))))))
#+(or abcl sbcl clisp)
(defun test-cl-ppcre ()
#+abcl (require "JVM")
(let ((*default-pathname-defaults* #-(or windows mswindows win32)
#p"/home/peter/cl-ppcre-1.2.19/"
#+(or windows mswindows win32)
#p"c:\\cygwin\\home\\peter\\cl-ppcre-1.2.19\\"))
#+abcl
(map nil #'delete-file (directory "*.abcl"))
#+sbcl
(map nil #'delete-file (directory "*.fasl"))
(load "load.lisp")
(let ((f (find-symbol "TEST" "CL-PPCRE-TEST")))
(when f
#+abcl (gc)
(time (funcall f))
#+abcl (gc)
(time (funcall f))))))
#+abcl
(defun run-other-tests ()
(test-cl-ppcre)
(let ((*default-pathname-defaults* "/home/peter/salza-0.7.2/"))
(map nil #'delete-file (directory "*.abcl"))
(load "/home/peter/test-salza.lisp")
(gc)
(test-salza)
(gc)
(test-salza)))
#+abcl
(autoload 'do-tests "rt.lisp")
#+allegro
(top-level:alias "ap" (arg) (apropos arg nil nil t))
#+allegro
(top-level:alias "de" (arg) (describe (eval arg)))
#+cmu
(setf *gc-verbose* nil)
;; #+sbcl
;; (require '#:asdf)
;; #+sbcl
;; (require '#:sb-aclrepl)
|