From 2ed24ef29443d3a8d4186353841adc59d106a6be Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Tue, 23 Apr 1996 21:10:56 +0000 Subject: [PATCH] Improve SF-CONDITIONALLY to use same pathname-type defaulting that SF does. --- v7/src/compiler/machines/i386/compiler.sf | 8 ++++---- v7/src/cref/cref.sf | 8 ++++---- v7/src/edwin/edwin.sf | 9 ++++----- v7/src/runtime/runtime.sf | 14 +++++++++---- v7/src/sf/butils.scm | 24 +++++++++++++---------- v7/src/sf/sf.sf | 8 ++++---- 6 files changed, 40 insertions(+), 31 deletions(-) diff --git a/v7/src/compiler/machines/i386/compiler.sf b/v7/src/compiler/machines/i386/compiler.sf index 7e128db2c..8dcf139a4 100644 --- a/v7/src/compiler/machines/i386/compiler.sf +++ b/v7/src/compiler/machines/i386/compiler.sf @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: compiler.sf,v 1.7 1995/01/06 18:38:37 cph Exp $ +$Id: compiler.sf,v 1.8 1996/04/23 21:05:30 cph Exp $ -Copyright (c) 1992-95 Massachusetts Institute of Technology +Copyright (c) 1992-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -104,5 +104,5 @@ MIT in each case. |# ;; Rebuild the package constructors and cref. (cref/generate-constructors "compiler") -(sf "compiler.con") -(sf "compiler.ldr") \ No newline at end of file +(sf-conditionally "compiler.con") +(sf-conditionally "compiler.ldr") \ No newline at end of file diff --git a/v7/src/cref/cref.sf b/v7/src/cref/cref.sf index 89ad48700..336477421 100644 --- a/v7/src/cref/cref.sf +++ b/v7/src/cref/cref.sf @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: cref.sf,v 1.8 1995/01/06 19:25:59 cph Exp $ +$Id: cref.sf,v 1.9 1996/04/23 21:09:04 cph Exp $ -Copyright (c) 1988-95 Massachusetts Institute of Technology +Copyright (c) 1988-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -45,5 +45,5 @@ MIT in each case. |# (begin (load-option 'CREF) (cref/generate-constructors "cref") - (sf "cref.con") - (sf "cref.ldr"))) \ No newline at end of file + (sf-conditionally "cref.con") + (sf-conditionally "cref.ldr"))) \ No newline at end of file diff --git a/v7/src/edwin/edwin.sf b/v7/src/edwin/edwin.sf index 915b523cb..16b459f67 100644 --- a/v7/src/edwin/edwin.sf +++ b/v7/src/edwin/edwin.sf @@ -1,8 +1,8 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: edwin.sf,v 1.17 1995/11/04 05:58:44 cph Exp $ +;;; $Id: edwin.sf,v 1.18 1996/04/23 21:09:51 cph Exp $ ;;; -;;; Copyright (c) 1991-95 Massachusetts Institute of Technology +;;; Copyright (c) 1991-96 Massachusetts Institute of Technology ;;; ;;; This material was developed by the Scheme project at the ;;; Massachusetts Institute of Technology, Department of @@ -108,12 +108,11 @@ (write-globals pathname pmodel) (write-constructor pathname pmodel)))))) (generate package-name) - (sf (pathname-new-type package-name "con")) + (sf-conditionally (pathname-new-type package-name "con")) (if (and (file-exists? (pathname-new-type package-name "avd")) (not (file-processed? package-name "avd" "bad"))) (fasdump (read-file (pathname-new-type package-name "avd")) (pathname-new-type package-name "bad")))) -(if (not (file-processed? "edwin" "ldr" "bld")) - (sf "edwin.ldr")) +(sf-conditionally "edwin.ldr") ) \ No newline at end of file diff --git a/v7/src/runtime/runtime.sf b/v7/src/runtime/runtime.sf index ae0bdf8a5..5bd9e100b 100644 --- a/v7/src/runtime/runtime.sf +++ b/v7/src/runtime/runtime.sf @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: runtime.sf,v 14.11 1995/01/06 18:37:20 cph Exp $ +$Id: runtime.sf,v 14.12 1996/04/23 21:10:56 cph Exp $ -Copyright (c) 1988-95 Massachusetts Institute of Technology +Copyright (c) 1988-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -33,6 +33,12 @@ promotional, or sales literature without prior written consent from MIT in each case. |# (fluid-let ((sf/default-syntax-table syntax-table/system-internal)) + (sf-conditionally "char") + (sf-conditionally "graphics") + (sf-conditionally "infstr") + (sf-conditionally "os2winp") + (sf-conditionally "gentag") + (sf-conditionally "gencache") (sf-directory ".")) ;; Guarantee that the package modeller is loaded. load-option ensures @@ -40,7 +46,7 @@ MIT in each case. |# ;; is loaded. (load-option 'CREF) (cref/generate-constructors "runtime") -(sf "runtime.con") -(sf "runtime.ldr") +(sf-conditionally "runtime.con") +(sf-conditionally "runtime.ldr") (if (file-exists? "runtime.avd") (fasdump (read-file "runtime.avd") "runtime.bad")) \ No newline at end of file diff --git a/v7/src/sf/butils.scm b/v7/src/sf/butils.scm index 742899fb9..39ce729a2 100644 --- a/v7/src/sf/butils.scm +++ b/v7/src/sf/butils.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: butils.scm,v 4.8 1993/11/09 04:17:02 gjr Exp $ +$Id: butils.scm,v 4.9 1996/04/23 21:01:48 cph Exp $ -Copyright (c) 1988-1993 Massachusetts Institute of Technology +Copyright (c) 1988-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -100,14 +100,18 @@ MIT in each case. |# (define (sf-conditionally filename #!optional echo-up-to-date?) (let ((kernel (lambda (filename) - (cond ((not (file-processed? filename "scm" "bin")) - (sf filename)) - ((and (not (default-object? echo-up-to-date?)) - echo-up-to-date?) - (newline) - (write-string "Syntax file: ") - (write filename) - (write-string " is up to date")))))) + (call-with-values + (lambda () (sf/pathname-defaulting filename #f #f)) + (lambda (input output spec) + spec + (cond ((not (compare-file-modification-times input output)) + (sf filename)) + ((and (not (default-object? echo-up-to-date?)) + echo-up-to-date?) + (newline) + (write-string "Syntax file: ") + (write filename) + (write-string " is up to date")))))))) (if (pair? filename) (for-each kernel filename) (kernel filename)))) diff --git a/v7/src/sf/sf.sf b/v7/src/sf/sf.sf index c2e5d99b1..cd1cb4daf 100644 --- a/v7/src/sf/sf.sf +++ b/v7/src/sf/sf.sf @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: sf.sf,v 4.6 1995/01/06 18:36:33 cph Exp $ +$Id: sf.sf,v 4.7 1996/04/23 21:04:44 cph Exp $ -Copyright (c) 1988-95 Massachusetts Institute of Technology +Copyright (c) 1988-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -54,5 +54,5 @@ MIT in each case. |# (load-option 'CREF) (cref/generate-constructors "sf") -(sf "sf.con") -(sf "sf.ldr") \ No newline at end of file +(sf-conditionally "sf.con") +(sf-conditionally "sf.ldr") \ No newline at end of file -- 2.25.1