Echo output from CREF (if any).
authorJoe Marshall <eval.apply@gmail.com>
Sat, 19 May 2012 17:28:04 +0000 (10:28 -0700)
committerJoe Marshall <eval.apply@gmail.com>
Sat, 19 May 2012 17:28:04 +0000 (10:28 -0700)
src/etc/compile.scm

index b1642b09c8d8641e98e791760dc880e6346411c6..757212455626de2ff79973cbb93540d261099eff 100644 (file)
@@ -72,8 +72,19 @@ USA.
       (if (file-exists? (pathname-new-type name "sf"))
          (begin
            (load (pathname-new-type name "sf"))
+           (echo-cref-output name)
            (load (pathname-new-type name "cbf")))
          (load "compile")))))
+
+(define (echo-cref-output name)
+  (let ((cref-output-file (pathname-new-type (package-set-pathname name) "crf")))
+    (if (file-exists? cref-output-file)
+       (call-with-input-file cref-output-file
+         (lambda (inport)
+           (do ((line (read-line inport) (read-line inport)))
+               ((eof-object? line))
+             (write-string line)
+             (newline)))))))
 \f
 (define (compile-bootstrap-1)
   (load-option 'SF)