diff options
author | jkh <jkh@FreeBSD.org> | 1999-08-08 07:51:16 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1999-08-08 07:51:16 +0000 |
commit | d58be4a80e2f1a8ee87f84f2021f51ce21b6f525 (patch) | |
tree | 9011368fa57dcf6baae64d9f85f7b191021460a1 /sys/conf/newvers.sh | |
parent | f0457b9b573c2f7894e1d736e155613ab2ff5371 (diff) | |
download | FreeBSD-src-d58be4a80e2f1a8ee87f84f2021f51ce21b6f525.zip FreeBSD-src-d58be4a80e2f1a8ee87f84f2021f51ce21b6f525.tar.gz |
The following simplifies newvers.sh somewhat and makes what(1) work with
kernels again, now that we're using EGCS/GCC 2.9+. This "here"
file is compatible with the Bourne shell and the Korn shell (incl. pdksh
and KSH93 from AT&T, which I do have), so it doesn't make newvers.sh
unportable, but makes it easier to modify in the future/read now.
Submitted by: green
Diffstat (limited to 'sys/conf/newvers.sh')
-rw-r--r-- | sys/conf/newvers.sh | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index fab46a9..0bde014 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -32,7 +32,7 @@ # SUCH DAMAGE. # # @(#)newvers.sh 8.1 (Berkeley) 4/20/94 -# $Id: newvers.sh,v 1.41 1998/11/01 15:36:20 wosch Exp $ +# $Id: newvers.sh,v 1.42 1999/01/21 03:07:33 jkh Exp $ TYPE="FreeBSD" REVISION="4.0" @@ -90,12 +90,14 @@ fi touch version v=`cat version` u=${USER-root} d=`pwd` h=`hostname` t=`date` -echo "$COPYRIGHT" > vers.c -echo "char ostype[] = \"${TYPE}\";" >> vers.c -echo "char osrelease[] = \"${RELEASE}\";" >> vers.c -echo "int osreldate = ${RELDATE};" >> vers.c -echo "char sccs[4] = { '@', '(', '#', ')' };" >>vers.c -echo "char version[] = \ - \"${VERSION} #${v}: ${t}\\n ${u}@${h}:${d}\\n\";" >>vers.c +cat << EOF > vers.c +$COPYRIGHT +char sccspad[32 - 4 /* sizeof(sccs) */] = { '\\0' }; +char sccs[4] = { '@', '(', '#', ')' }; +char version[] = "${VERSION} #${v}: ${t}\\n ${u}@${h}:${d}\\n"; +char ostype[] = "${TYPE}"; +char osrelease[] = "${RELEASE}"; +int osreldate = ${RELDATE}; +EOF echo `expr ${v} + 1` > version |