Conditionalize output file extension.
authorGuillermo J. Rozas <edu/mit/csail/zurich/gjr>
Tue, 9 Nov 1993 04:14:48 +0000 (04:14 +0000)
committerGuillermo J. Rozas <edu/mit/csail/zurich/gjr>
Tue, 9 Nov 1993 04:14:48 +0000 (04:14 +0000)
v7/src/compiler/base/asstop.scm
v7/src/compiler/base/toplev.scm
v7/src/compiler/machines/C/ctop.scm

index 546803b35b5ce2b33a2a96719e10ed3bc210a56c..8a4ad13a3f21d9d5ee098a861c3c8132e6cc0479 100644 (file)
@@ -1,6 +1,6 @@
 #| -*-Scheme-*-
 
-$Id: asstop.scm,v 1.6 1993/08/26 05:49:41 gjr Exp $
+$Id: asstop.scm,v 1.7 1993/11/09 04:13:55 gjr Exp $
 
 Copyright (c) 1988-1993 Massachusetts Institute of Technology
 
@@ -39,6 +39,8 @@ MIT in each case. |#
 \f
 ;;;; Exports to the compiler
 
+(define compiled-output-extension "com")
+
 (define (compiler-file-output object pathname)
   (fasdump object pathname))
 
index 62d89fae7fec091651965cf38dc364cf60a7eaf8..4bb1c1881ae197244e38a8209caa4de1d46ab1fa 100644 (file)
@@ -1,8 +1,8 @@
 #| -*-Scheme-*-
 
-$Id: toplev.scm,v 4.47 1992/10/24 16:00:50 jinx Exp $
+$Id: toplev.scm,v 4.48 1993/11/09 04:14:01 gjr Exp $
 
-Copyright (c) 1988-1992 Massachusetts Institute of Technology
+Copyright (c) 1988-1993 Massachusetts Institute of Technology
 
 This material was developed by the Scheme project at the Massachusetts
 Institute of Technology, Department of Electrical Engineering and
@@ -95,7 +95,8 @@ MIT in each case. |#
            (let ((input-pathname (merge-pathnames input-string default)))
              (let ((output-pathname
                     (let ((output-pathname
-                           (pathname-new-type input-pathname "com")))
+                           (pathname-new-type input-pathname
+                                              compiled-output-extension)))
                       (if output-string
                           (merge-pathnames output-string output-pathname)
                           output-pathname))))
@@ -106,7 +107,8 @@ MIT in each case. |#
                      (write (enough-namestring input-pathname))
                      (write-string " => ")
                      (write (enough-namestring output-pathname))))
-               (compiler-file-output (transform input-pathname output-pathname)
+               (compiler-file-output
+                (transform input-pathname output-pathname)
                                      output-pathname)))))
         (kernel
          (if compiler:batch-mode?
index cb474a96b60ba8fb4ca9905b2c54d5e6286c0ced..2358260903e5a218209782e3831ea19259d09da4 100644 (file)
@@ -1,8 +1,8 @@
 #| -*-Scheme-*-
 
-$Id: ctop.scm,v 1.2 1993/10/30 12:58:09 gjr Exp $
+$Id: ctop.scm,v 1.3 1993/11/09 04:14:48 gjr Exp $
 
-Copyright (c) 1992 Massachusetts Institute of Technology
+Copyright (c) 1992-1993 Massachusetts Institute of Technology
 
 This material was developed by the Scheme project at the Massachusetts
 Institute of Technology, Department of Electrical Engineering and
@@ -39,15 +39,13 @@ MIT in each case. |#
 \f
 ;;;; Exports to the compiler
 
-(define c-code-tag (string->symbol "#[C-code]"))
+(define compiled-output-extension "c")
 
 (define (compiler-file-output object pathname)
   (let ((pair (vector-ref object 1)))
-    (call-with-output-file (pathname-new-type pathname "c")
+    (call-with-output-file pathname
       (lambda (port)
-       (write-string (cdr pair) port)))
-    (fasdump (cons c-code-tag (car pair))
-            pathname)))
+       (write-string (cdr pair) port)))))
 
 (define (compiled-scode->procedure compiled-scode environment)
   environment                          ; ignored