diff --git a/code/commandline.lisp b/code/commandline.lisp index fc2bf09855ef972f099782de6ac3abbd2ec6b63d..f92b2eca53183585c5b20fdcb020b9a4b33dfe44 100644 --- a/code/commandline.lisp +++ b/code/commandline.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/commandline.lisp,v 1.7 2000/08/24 19:55:29 dtc Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/commandline.lisp,v 1.8 2000/10/16 17:30:06 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -191,11 +191,6 @@ (load (cmd-switch-arg switch))) (defswitch "load" #'load-switch-demon) -(defun batch-switch-demon (switch) - (setq *batch-mode* t) - (setf (cmd-switch-value switch) t)) -(defswitch "batch" #'batch-switch-demon) - (defun cmd-switch-arg (switch) (or (cmd-switch-value switch) (car (cmd-switch-words switch)) @@ -205,4 +200,4 @@ (defswitch "init") (defswitch "noinit") (defswitch "hinit") - +(defswitch "batch") diff --git a/compiler/alpha/parms.lisp b/compiler/alpha/parms.lisp index d474cee0487f4021fe1c0f298c38bfccf633c4b3..99da9804424ae1d8f8a2834c0395804a989a2697 100644 --- a/compiler/alpha/parms.lisp +++ b/compiler/alpha/parms.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/alpha/parms.lisp,v 1.5 1999/02/20 15:54:41 pw Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/alpha/parms.lisp,v 1.6 2000/10/16 17:30:06 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -191,6 +191,7 @@ ;; The C startup code must fill these in. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* lisp::*initial-fdefn-objects* ;; Functions that the C code needs to call diff --git a/compiler/hppa/parms.lisp b/compiler/hppa/parms.lisp index f7d64f43904d2d2fd2303669e2e0fa7dd1d236ec..2a5e86ac642bcecca42c638c1a6a37b24958c13a 100644 --- a/compiler/hppa/parms.lisp +++ b/compiler/hppa/parms.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/hppa/parms.lisp,v 1.6 1998/09/13 12:27:13 dtc Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/hppa/parms.lisp,v 1.7 2000/10/16 17:30:06 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -179,6 +179,7 @@ ;; The C startup code must fill these in. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* lisp::*initial-fdefn-objects* ;; Functions that the C code needs to call diff --git a/compiler/mips/parms.lisp b/compiler/mips/parms.lisp index ac6aff16584d7ddf7dd9c81e9553a1c6924bcf00..efcae0d4d03d71e46c00e273bed2455af5a33f36 100644 --- a/compiler/mips/parms.lisp +++ b/compiler/mips/parms.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/parms.lisp,v 1.112 1997/08/23 16:00:15 pw Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/mips/parms.lisp,v 1.113 2000/10/16 17:30:07 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -196,6 +196,7 @@ ;; Random stuff needed for initialization. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* lisp::*initial-fdefn-objects* ;; Functions that the C code needs to call @@ -229,6 +230,7 @@ ;; Random stuff needed for initialization. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* ;; Functions that the C code needs to call kernel::internal-error diff --git a/compiler/sparc/parms.lisp b/compiler/sparc/parms.lisp index e58d6915b6a02c555bc3aa3a7e500660bb6f425d..cfb491bcea1b12eacd9861901f4a11447e8448eb 100644 --- a/compiler/sparc/parms.lisp +++ b/compiler/sparc/parms.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/parms.lisp,v 1.27 1998/03/21 08:05:24 dtc Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/sparc/parms.lisp,v 1.28 2000/10/16 17:30:08 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -220,6 +220,7 @@ ;; The C startup code must fill these in. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* lisp::*initial-fdefn-objects* ;; Functions that the C code needs to call diff --git a/compiler/x86/parms.lisp b/compiler/x86/parms.lisp index 141930c0b844a8ec12d5e7dea4a11cf015c13bb6..18dc12816a87c532420882457f3337d3fcfda8e9 100644 --- a/compiler/x86/parms.lisp +++ b/compiler/x86/parms.lisp @@ -7,7 +7,7 @@ ;;; Scott Fahlman or slisp-group@cs.cmu.edu. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/x86/parms.lisp,v 1.15 1999/09/16 15:48:23 dtc Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/x86/parms.lisp,v 1.16 2000/10/16 17:30:08 dtc Exp $") ;;; ;;; ********************************************************************** ;;; @@ -237,6 +237,7 @@ ;; The C startup code must fill these in. lisp::lisp-environment-list lisp::lisp-command-line-list + ext::*batch-mode* lisp::*initial-fdefn-objects* ;; Functions that the C code needs to call diff --git a/lisp/lisp.c b/lisp/lisp.c index 8b67a2de593a4493391742a8ec25def821055aa6..5c562f207633450ccb912b8c216e1b7fd3e8af5d 100644 --- a/lisp/lisp.c +++ b/lisp/lisp.c @@ -1,7 +1,7 @@ /* * main() entry point for a stand alone lisp image. * - * $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/lisp.c,v 1.16 1999/09/09 16:22:44 pw Exp $ + * $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/lisp.c,v 1.17 2000/10/16 17:30:01 dtc Exp $ * */ @@ -89,6 +89,7 @@ void main(int argc, char *argv[], char *envp[]) char *arg, **argptr; char *core = NULL, *default_core; boolean monitor; + lispobj batch_mode; lispobj initial_function; #ifdef MACH @@ -101,6 +102,7 @@ void main(int argc, char *argv[], char *envp[]) set_lossage_handler(ldb_monitor); monitor = FALSE; + batch_mode = NIL; argptr = argv; while ((arg = *++argptr) != NULL) { @@ -118,6 +120,9 @@ void main(int argc, char *argv[], char *envp[]) else if (strcmp(arg, "-monitor") == 0) { monitor = TRUE; } + else if (strcmp(arg, "-batch") == 0) { + batch_mode = T; + } } default_core = arch_init(); @@ -215,6 +220,7 @@ void main(int argc, char *argv[], char *envp[]) /* Convert the argv and envp to something Lisp can grok. */ SetSymbolValue(LISP_COMMAND_LINE_LIST, alloc_str_list(argv)); SetSymbolValue(LISP_ENVIRONMENT_LIST, alloc_str_list(envp)); + SetSymbolValue(BATCH_MODE, batch_mode); /* Pick off sigint until the lisp system gets far enough along to */ /* install it's own. */