From 3106aee96a20d1a76a114e504bc2931f8196cace Mon Sep 17 00:00:00 2001 From: Juho Snellman Date: Fri, 16 Mar 2007 03:57:08 +0000 Subject: [PATCH] 1.0.3.40: :EXECUTABLE T implies --noinform * Patch from Kevin Reid. * Not the right solution. This can be revisited once somebody implements the mythical saving of command-line parameters into the core. * Also check in some fixes to the build process of the manual (patch by Richard Kreuter). --- NEWS | 3 +++ doc/manual/Makefile | 16 ++++++++++------ src/runtime/runtime.c | 2 +- tests/core.test.sh | 28 ++++++++++++++++++++++++++-- version.lisp-expr | 2 +- 5 files changed, 41 insertions(+), 10 deletions(-) diff --git a/NEWS b/NEWS index 037579f..1fe8e06 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,9 @@ changes in sbcl-1.0.4 relative to sbcl-1.0.3: and gethostbyname, on platforms where the newer functions are available. As a result, the ALIASES field of HOST-ENT will always be NIL on these platforms. + * change: runtimes with embedded cores (i.e. saved with :EXECUTABLE T) + don't print the startup banner, but behave as if --noinform was passed + as a command line argument. (thanks to Kevin Reid) * optimization: code using alien values with undeclared types is much faster. * optimization: the compiler is now able to open code SEARCH in more cases. * optimization: more compact typechecks on x86-64 (thanks to Lutz Euler) diff --git a/doc/manual/Makefile b/doc/manual/Makefile index 45f89ea..6a54d40 100644 --- a/doc/manual/Makefile +++ b/doc/manual/Makefile @@ -11,9 +11,9 @@ HTMLDIRS=$(basename $(SBCLTEXI)) $(basename $(ASDFTEXI)) # DOCSTRINGDIR has to end with a slash or you lose (it's passed to # Lisp's `pathname' function). DOCSTRINGDIR="docstrings/" -I_FLAGS=-I $(DOCSTRINGDIR) -I ../../contrib/ +CONTRIBDIR="../../contrib/" +I_FLAGS=-I $(DOCSTRINGDIR) -I $(CONTRIBDIR) # List of contrib modules that docstring docs will be created for. -# FIXME: should check test-passed and not load them. MODULES=':sb-md5 :sb-rotate-byte :sb-grovel :sb-sprof :sb-bsd-sockets' # List of package names that docstring docs will be created for. PACKAGES=":COMMON-LISP :SB-ALIEN :SB-DEBUG :SB-EXT :SB-GRAY :SB-MOP :SB-PROFILE :SB-THREAD :SB-MD5 :SB-ROTATE-BYTE :SB-SPROF :SB-BSD-SOCKETS" @@ -83,12 +83,16 @@ info: $(INFOFILES) $(MAKEINFO) $(I_FLAGS) $< # Texinfo docstring snippets -.PHONY: docstrings -docstrings: tempfiles-stamp +# Note: assumes contrib module names are the same as the names of +# directories containing the modules, and that these directories +# are in $(CONTRIBDIR). +CONTRIB_FASLS=$(shell find $(shell echo $(MODULES) | sed "s|:|$(CONTRIBDIR)|g") -name '*.fasl') +docstrings: ../../output/sbcl.core $(CONTRIB_FASLS) tempfiles-stamp + for module in $(shell echo $(MODULES)); do test -e $(CONTRIBDIR)/$${module#:}/test-passed || { echo "The documented contrib $$module seems to have failed its tests." && exit 1; }; done + DOCSTRINGDIR=$(DOCSTRINGDIR) PACKAGES=$(PACKAGES) MODULES=$(MODULES) sh make-tempfiles.sh "$(SBCL_SYSTEM)" && touch $(DOCSTRINGDIR) tempfiles-stamp: - DOCSTRINGDIR=$(DOCSTRINGDIR) PACKAGES=$(PACKAGES) MODULES=$(MODULES) sh make-tempfiles.sh "$(SBCL_SYSTEM)" && touch tempfiles-stamp - + touch tempfiles-stamp .PHONY: clean clean: diff --git a/src/runtime/runtime.c b/src/runtime/runtime.c index f2b52d6..ab61951 100644 --- a/src/runtime/runtime.c +++ b/src/runtime/runtime.c @@ -376,7 +376,7 @@ main(int argc, char *argv[], char *envp[]) free(copied_core); } - if (!noinform) { + if (!noinform && embedded_core_offset == 0) { print_banner(); fflush(stdout); } diff --git a/tests/core.test.sh b/tests/core.test.sh index 84c6a3d..1c5a0cf 100644 --- a/tests/core.test.sh +++ b/tests/core.test.sh @@ -14,7 +14,8 @@ # more information. tmpcore="core-test-sh-$$.core" -rm -f $tmpcore +tmpoutput="core-test-sh-$$.output.txt" +rm -f "$tmpcore" "$tmpoutput" # In sbcl-0.7.7 SAVE-LISP-AND-DIE didn't work at all because of # flakiness caused by consing/GC/purify twice-and-at-least-twice @@ -61,6 +62,29 @@ else exit 1 fi -rm -f $tmpcore +# test suppression of banner in executable cores +$SBCL <"$tmpoutput" --eval '(quit :unix-status 71)' +if [ $? != 71 ]; then + echo "failure in banner suppression: $?" + exit 1 +elif [ -s "$tmpoutput" ]; then + echo "failure in banner suppression: nonempty output:" + echo --- + cat "$tmpoutput" + echo --- + exit 1 +elif [ -f "$tmpoutput" ]; then + echo "/Executable suppressed banner, good." +else + echo "failure in banner suppression: $tmpoutput was not created or something funny happened." + exit 1 +fi + +rm -f "$tmpcore" +rm -f "$tmpoutput" echo "/returning success from core.test.sh" exit 104 diff --git a/version.lisp-expr b/version.lisp-expr index ea4db7a..c295eee 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"1.0.3.39" +"1.0.3.40" -- 1.7.10.4