Browse code
Mods to make it work
fiddlerwoaroof authored on 30/01/2017 19:59:23
Showing 5 changed files
Showing 5 changed files
- cl-support/cl-definitions.lisp
- cl-support/cl-init.lisp
- cl-support/cl-structs.lisp
- com/cmu/compile
- haskell-setup
... | ... |
@@ -104,7 +104,7 @@ |
104 | 104 |
|
105 | 105 |
|
106 | 106 |
;;; AKCL's SETF brokenly tries to macroexpand the place |
107 |
-;;; form before looking for a define-setf-method. Redefine the |
|
107 |
+;;; form before looking for a define-setf-expander Redefine the |
|
108 | 108 |
;;; internal function to do the right thing. |
109 | 109 |
|
110 | 110 |
#+akcl |
... | ... |
@@ -120,7 +120,7 @@ |
120 | 120 |
|
121 | 121 |
;;; Allegro has renamed this stuff as per ANSI CL. |
122 | 122 |
|
123 |
-#+allegro |
|
123 |
+#+(or cmu allegro) |
|
124 | 124 |
(eval-when (eval compile load) |
125 | 125 |
(setf (macro-function 'define-setf-method) |
126 | 126 |
(macro-function 'define-setf-expander)) |
... | ... |
@@ -147,7 +147,7 @@ |
147 | 147 |
(define-mumble-macro mumble::dynamic (name) |
148 | 148 |
`(locally (declare (special ,name)) ,name)) |
149 | 149 |
|
150 |
-(define-setf-method mumble::dynamic (name) |
|
150 |
+(define-setf-expander mumble::dynamic (name) |
|
151 | 151 |
(let ((store (gensym))) |
152 | 152 |
(values nil |
153 | 153 |
nil |
... | ... |
@@ -441,7 +441,7 @@ |
441 | 441 |
(define-mumble-import last) |
442 | 442 |
(define-mumble-import butlast) |
443 | 443 |
|
444 |
-(define-setf-method mumble::list-ref (list n) |
|
444 |
+(define-setf-expander mumble::list-ref (list n) |
|
445 | 445 |
(get-setf-method `(nth ,n ,list))) |
446 | 446 |
|
447 | 447 |
(define-mumble-function-inline mumble::memq (object list) |
... | ... |
@@ -566,7 +566,7 @@ |
566 | 566 |
(define-mumble-function-inline mumble::string-ref (x n) |
567 | 567 |
(the character (schar (the simple-string x) (the fixnum n)))) |
568 | 568 |
|
569 |
-(define-setf-method mumble::string-ref (string n) |
|
569 |
+(define-setf-expander mumble::string-ref (string n) |
|
570 | 570 |
(get-setf-method `(schar ,string ,n))) |
571 | 571 |
|
572 | 572 |
(define-mumble-synonym mumble::string=? string=) |
... | ... |
@@ -628,7 +628,7 @@ |
628 | 628 |
(define-mumble-function-inline mumble::vector-ref (x n) |
629 | 629 |
(svref (the simple-vector x) (the fixnum n))) |
630 | 630 |
|
631 |
-(define-setf-method mumble::vector-ref (vector n) |
|
631 |
+(define-setf-expander mumble::vector-ref (vector n) |
|
632 | 632 |
(get-setf-method `(svref ,vector ,n))) |
633 | 633 |
|
634 | 634 |
(define-mumble-function-inline mumble::vector->list (vector) |
... | ... |
@@ -722,7 +722,7 @@ |
722 | 722 |
(define-mumble-function-inline mumble::table-entry (table key) |
723 | 723 |
(gethash key table)) |
724 | 724 |
|
725 |
-(define-setf-method mumble::table-entry (table key) |
|
725 |
+(define-setf-expander mumble::table-entry (table key) |
|
726 | 726 |
(get-setf-method `(gethash ,key ,table))) |
727 | 727 |
|
728 | 728 |
(define-mumble-synonym mumble::table-for-each maphash) |
... | ... |
@@ -6,6 +6,10 @@ |
6 | 6 |
;;; All of the files loaded here are assumed to be regular Common Lisp |
7 | 7 |
;;; files. |
8 | 8 |
|
9 |
+(eval-when (:load-toplevel :compile-toplevel :execute) |
|
10 |
+ (unless (find-package "MUMBLE-IMPLEMENTATION") |
|
11 |
+ (make-package "MUMBLE-IMPLEMENTATION" :use '("LISP")))) |
|
12 |
+ |
|
9 | 13 |
(in-package "MUMBLE-IMPLEMENTATION") |
10 | 14 |
|
11 | 15 |
|
... | ... |
@@ -114,13 +118,14 @@ |
114 | 118 |
;;; Environment variables in pathnames may not be supported by the |
115 | 119 |
;;; host Lisp. |
116 | 120 |
|
117 |
-#-mcl (progn |
|
118 |
- (defvar *support-directory* "cl-support/") |
|
119 |
- (defvar *support-binary-directory* |
|
120 |
- (concatenate 'string |
|
121 |
- *support-directory* |
|
122 |
- *lisp-implementation-name* |
|
123 |
- "/"))) |
|
121 |
+#-mcl |
|
122 |
+(progn |
|
123 |
+ (defvar *support-directory* "cl-support/") |
|
124 |
+ (defvar *support-binary-directory* |
|
125 |
+ (concatenate 'string |
|
126 |
+ *support-directory* |
|
127 |
+ *lisp-implementation-name* |
|
128 |
+ "/"))) |
|
124 | 129 |
|
125 | 130 |
(defun load-compiled-cl-file (filename) |
126 | 131 |
(let ((source-file (concatenate 'string |
... | ... |
@@ -131,11 +136,14 @@ |
131 | 136 |
*support-binary-directory* |
132 | 137 |
filename |
133 | 138 |
*lisp-binary-file-type*))) |
139 |
+ (format t "~&CWD: ~a~%" (truename ".")) |
|
134 | 140 |
(if (or (not (probe-file binary-file)) |
135 | 141 |
(< (file-write-date binary-file) (file-write-date source-file))) |
136 | 142 |
(compile-file source-file :output-file (merge-pathnames binary-file))) |
137 | 143 |
(load binary-file))) |
138 | 144 |
|
145 |
+(eval-when (:load-toplevel :compile-toplevel :execute) |
|
146 |
+ (trace load-compiled-cl-file)) |
|
139 | 147 |
|
140 | 148 |
;;; Do NOT change the load order of these files. |
141 | 149 |
|
... | ... |
@@ -412,7 +412,7 @@ |
412 | 412 |
;; the BOA constructor. Bogus!!! |
413 | 413 |
;; If you do this in WCL, it will just quietly ignore |
414 | 414 |
;; the BOA. |
415 |
- #-(or akcl wcl) (:constructor nil) |
|
415 |
+ #-(or cmu akcl wcl) (:constructor nil) |
|
416 | 416 |
(:constructor ,(td-%constructor td) ,(make-boa-args slots)) |
417 | 417 |
(:predicate ,predicate) |
418 | 418 |
(:copier nil)) |
... | ... |
@@ -6,7 +6,7 @@ |
6 | 6 |
cd $Y2 |
7 | 7 |
$CMUCL <<EOF |
8 | 8 |
(setf ext:*bytes-consed-between-gcs* 4000000) |
9 |
-(proclaim '(optimize (speed 3) (safety 0) (debug 0) (ext:inhibit-warnings 3))) |
|
9 |
+(proclaim '(optimize (speed 0) (safety 0) (debug 3) (ext:inhibit-warnings 0))) |
|
10 | 10 |
(load "cl-support/cl-init") |
11 | 11 |
(quit) |
12 | 12 |
EOF |
... | ... |
@@ -8,20 +8,20 @@ setenv HASKELL_LIBRARY $HASKELL/progs/lib |
8 | 8 |
|
9 | 9 |
# You may need to change this to point at the appropriate subdirectory, |
10 | 10 |
# depending on which Lisp is being used. |
11 |
-setenv PRELUDEBIN $PRELUDE/lucid |
|
12 |
-#setenv PRELUDEBIN $PRELUDE/cmu |
|
11 |
+#setenv PRELUDEBIN $PRELUDE/lucid |
|
12 |
+setenv PRELUDEBIN $PRELUDE/cmu |
|
13 | 13 |
|
14 | 14 |
# You may need to change this to point at the appropriate subdirectory, |
15 | 15 |
# depending on which Lisp is being used. |
16 |
-setenv LIBRARYBIN $HASKELL_LIBRARY/bin/lucid |
|
17 |
-#setenv LIBRARYBIN $HASKELL_LIBRARY/bin/cmu |
|
16 |
+#setenv LIBRARYBIN $HASKELL_LIBRARY/bin/lucid |
|
17 |
+setenv LIBRARYBIN $HASKELL_LIBRARY/bin/cmu |
|
18 | 18 |
|
19 | 19 |
# You may need to change this to point at the appropriate executable, |
20 | 20 |
# depending on which Lisp is being used. |
21 |
-setenv HASKELLPROG $HASKELL/bin/haskell |
|
22 |
-#setenv HASKELLPROG $HASKELL/bin/cmu-haskell |
|
21 |
+#setenv HASKELLPROG $HASKELL/bin/haskell |
|
22 |
+setenv HASKELLPROG $HASKELL/bin/cmu-haskell |
|
23 | 23 |
|
24 | 24 |
# You only need this next definition if you are using the CMU CL version |
25 | 25 |
# of haskell and you have /tmp mounted on a tmpfs file system (it won't |
26 | 26 |
# be able to initialize itself otherwise). |
27 |
-setenv CMUCL_EMPTYFILE /var/tmp/empty |
|
27 |
+#setenv CMUCL_EMPTYFILE /var/tmp/empty |