diff --git a/compiler/main.lisp b/compiler/main.lisp index 9a2dd9972a55931504bdf74178134c381d94af8b..a4bbefd383f7b93564e45c545bc7c6c203e78fce 100644 --- a/compiler/main.lisp +++ b/compiler/main.lisp @@ -1126,11 +1126,13 @@ (setf (default-directory) cwd)))) (generate-comment (file-info) (let* ((name (pathname (source-info-stream file-info))) - (proc (run-git name))) - (if (and proc (zerop (process-exit-code proc))) + (proc (run-git name)) + comment) + (if (and proc (zerop (process-exit-code proc)) + (setf comment (read-line (process-output proc) nil nil))) (format nil "$Header: ~A ~A $" (enough-namestring name) - (read-line (process-output proc))) + comment) (second form))))) (cond ((file-info-comment file) (compiler-warning _N"Ignoring extra file comment:~% ~S." form)) diff --git a/tools/build-all.sh b/tools/build-all.sh index c2462b436ca1388b7ef3c200c47901501170d47f..3b69e1c00ed4815b16e29926329b878e21faba77 100755 --- a/tools/build-all.sh +++ b/tools/build-all.sh @@ -63,21 +63,20 @@ if [ "$OLDLISP" = "" -a "$OLD8" = "" ]; then exit 1 fi -VERSION=${VERSION:+-v "$VERSION"} buildx86 () { if [ -n "$OLD8" ]; then # Build non-unicode versions set -x - src/tools/build.sh -f x87 -b ${BASE}-8bit $bootfiles "$VERSION" -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" - src/tools/build.sh -f sse2 -b ${BASE}-8bit $bootfiles "$VERSION" -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" + src/tools/build.sh -f x87 -b ${BASE}-8bit $bootfiles ${VERSION:+-v "$VERSION"} -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" + src/tools/build.sh -f sse2 -b ${BASE}-8bit $bootfiles ${VERSION:+-v "$VERSION"} -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" set +x fi # Build the unicode versions if [ -n "$OLDLISP" ]; then set -x - src/tools/build.sh -f x87 -b ${BASE} $bootfiles "$VERSION" -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" - src/tools/build.sh -f sse2 -b ${BASE} $bootfiles "$VERSION" -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" + src/tools/build.sh -f x87 -b ${BASE} $bootfiles ${VERSION:+-v "$VERSION"} -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" + src/tools/build.sh -f sse2 -b ${BASE} $bootfiles ${VERSION:+-v "$VERSION"} -C "${CREATE_OPT}" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" set +x fi } @@ -87,13 +86,13 @@ buildsun4 () # Build non-unicode versions if [ -n "$OLD8" ]; then set -x - src/tools/build.sh -b ${BASE}-8bit $bootfiles "$VERSION" -C "$CREATE_OPT" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" + src/tools/build.sh -b ${BASE}-8bit $bootfiles ${VERSION:+-v "$VERSION"} -C "$CREATE_OPT" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLD8" set +x fi # Build the unicode version. if [ -n "$OLDLISP" ]; then set -x - src/tools/build.sh -b ${BASE} $bootfiles "$VERSION" -C "$CREATE_OPT" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" + src/tools/build.sh -b ${BASE} $bootfiles ${VERSION:+-v "$VERSION"} -C "$CREATE_OPT" ${UPDATE_TRANS} ${UPDATE_POT} -o "$OLDLISP" set +x fi } diff --git a/tools/create-target.sh b/tools/create-target.sh index 7c0854c4b1ee4f3db7df973832054b0146fb8c73..e420f5c319bb38be96e7293cc5de93dceb378c3f 100755 --- a/tools/create-target.sh +++ b/tools/create-target.sh @@ -92,7 +92,7 @@ cd $bld_dir/lisp || quit "Can't cd $bld_dir/lisp" ln -s ../../src/lisp/GNUmakefile ../../src/lisp/Config.$lisp_variant ../../src/lisp/Config.*_common . ln -s Config.$lisp_variant Config [ -n "$motif_variant" ] && ( - cd motif/server || quit "Can't cd motif/server" # We will still continue in the outer shell + cd ../motif/server || quit "Can't cd motif/server" # We will still continue in the outer shell ln -s ../../../src/motif/server/GNUmakefile ./Makefile ln -s ../../../src/motif/server/Config.$motif_variant ./Config ) diff --git a/tools/load-world.sh b/tools/load-world.sh index 672a357d59d7ff682284ad9bb06d20d947823f11..288e40c04588d61252cd29f56983a47e1ecd33ab 100755 --- a/tools/load-world.sh +++ b/tools/load-world.sh @@ -11,8 +11,10 @@ usage() SKIP_PCL= NO_PCL_FEATURE= -# Default version is the date. -VERSION="CVS Head `date '+%Y-%m-%d %H:%M:%S'`" +# Default version is the date with the git hash. +GIT_HASH="`(cd src; git describe --dirty 2>/dev/null)`" +VERSION="`date '+%Y-%m-%d %H:%M:%S'`${GIT_HASH:+ $GIT_HASH}" +echo $VERSION while getopts "p" arg do @@ -40,7 +42,7 @@ fi # If version string give, use it, otherwise use the default. if [ -n "$2" ]; then - VERSION=$2 + VERSION="$2" fi $TARGET/lisp/lisp -core $TARGET/lisp/kernel.core <