From 9d3f0aee1f6f022a62ee2c8c6c3553210c96d97a Mon Sep 17 00:00:00 2001 From: "Guillermo J. Rozas" Date: Sat, 22 Aug 1992 15:03:25 +0000 Subject: [PATCH] Observe compiler:cross-compiling? --- v7/src/compiler/etc/xcbfdir.scm | 11 ++++++++--- v7/src/sf/butils.scm | 17 ++++++++++++----- v8/src/compiler/etc/xcbfdir.scm | 11 ++++++++--- 3 files changed, 28 insertions(+), 11 deletions(-) diff --git a/v7/src/compiler/etc/xcbfdir.scm b/v7/src/compiler/etc/xcbfdir.scm index b143401ac..a1e616f7b 100644 --- a/v7/src/compiler/etc/xcbfdir.scm +++ b/v7/src/compiler/etc/xcbfdir.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/etc/xcbfdir.scm,v 1.7 1991/05/27 17:56:12 jinx Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/compiler/etc/xcbfdir.scm,v 1.8 1992/08/22 15:00:49 jinx Exp $ -Copyright (c) 1989-91 Massachusetts Institute of Technology +Copyright (c) 1989-1992 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -78,7 +78,12 @@ MIT in each case. |# (->pathname "*.bin"))))) (define (recompile-directory dir) - (process-directory dir compile-bin-file "com")) + (let ((extn + (if (access compiler:cross-compiling? + (->environment '(compiler))) + "moc" + "com"))) + (process-directory dir compile-bin-file extn))) (define (cross-compile-directory dir) (process-directory dir cross-compile-bin-file "moc")) \ No newline at end of file diff --git a/v7/src/sf/butils.scm b/v7/src/sf/butils.scm index 79be51492..bb32327ea 100644 --- a/v7/src/sf/butils.scm +++ b/v7/src/sf/butils.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/sf/butils.scm,v 4.5 1991/11/04 20:31:36 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/sf/butils.scm,v 4.6 1992/08/22 15:03:25 jinx Exp $ -Copyright (c) 1988-91 Massachusetts Institute of Technology +Copyright (c) 1988-1992 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -48,7 +48,8 @@ MIT in each case. |# (lambda (input-directory #!optional output-directory force?) (let ((output-directory (if (default-object? output-directory) false output-directory)) - (force? (if (default-object? force?) false force?))) + (force? (if (default-object? force?) false force?)) + (output-type (output-type))) (for-each (lambda (pathname) (if (or force? (not (compare-file-modification-times @@ -66,12 +67,18 @@ MIT in each case. |# (directory-read input-directory))))))) (define sf-directory - (directory-processor "scm" "bin" + (directory-processor "scm" + (lambda () "bin") (lambda (pathname output-directory) (sf pathname output-directory)))) (define compile-directory - (directory-processor "bin" "com" + (directory-processor "bin" + (lambda () + (if (access compiler:cross-compiling? + (->environment '(compiler))) + "moc" + "com")) (lambda (pathname output-directory) (compile-bin-file pathname output-directory)))) diff --git a/v8/src/compiler/etc/xcbfdir.scm b/v8/src/compiler/etc/xcbfdir.scm index b8aee03ba..80e0482a6 100644 --- a/v8/src/compiler/etc/xcbfdir.scm +++ b/v8/src/compiler/etc/xcbfdir.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/compiler/etc/xcbfdir.scm,v 1.7 1991/05/27 17:56:12 jinx Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/compiler/etc/xcbfdir.scm,v 1.8 1992/08/22 15:00:49 jinx Exp $ -Copyright (c) 1989-91 Massachusetts Institute of Technology +Copyright (c) 1989-1992 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -78,7 +78,12 @@ MIT in each case. |# (->pathname "*.bin"))))) (define (recompile-directory dir) - (process-directory dir compile-bin-file "com")) + (let ((extn + (if (access compiler:cross-compiling? + (->environment '(compiler))) + "moc" + "com"))) + (process-directory dir compile-bin-file extn))) (define (cross-compile-directory dir) (process-directory dir cross-compile-bin-file "moc")) \ No newline at end of file -- 2.25.1