home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
pc.louisiana.edu/pub/unix/
/
Louisiana_UNIX.tar
/
Louisiana_UNIX
/
newvers.diff
< prev
next >
Wrap
Text File
|
1996-09-20
|
3KB
|
81 lines
Context diff of changes to /sys/conf.common/newvers, to scan for
symlinks in the /sys/sun4*/OBJ dir, so that patches can be named in the
generated vmunix file, and shown by the ident program.
-- James Dugal, jpd@usl.edu
========================================================================
*** newvers.sh.orig Wed Oct 6 19:37:36 1993
--- newvers.sh Tue May 17 15:54:31 1994
***************
*** 1,3 ****
--- 1,23 ----
+ #
+ # $Header: /h1/staff/RCS/newvers.sh,v 1.2 1991/11/11 16:40:34 root Exp $
+ #
+ # $Log: newvers.sh,v $
+ # Revision 1.2 1991/11/11 16:40:34 root
+ # Applied mods to track patches applied to kernel.
+ # Essentially, in the OBJ dir, create a synbolic link to the actual .o file,
+ # and name it with the patch number, as in: ln -s foo.o foo.o-100956-02
+ #
+ # Revision 1.3 1991/10/08 06:37:59 kernel
+ # Added code to insert version of configuration file
+ # Added code to build dummy rcsid string with indications of patched
+ # objects
+ #
+ # Revision 1.2 1991/10/07 17:12:23 kernel
+ # Added RCS identification string
+ #
+ #
+ #
+
# called by: newvers.sh <release_file> <arch>
PATH=/usr/ucb:/bin:/usr/bin
***************
*** 18,24 ****
echo '#include <sys/utsname.h>' > vers.c
echo >> vers.c
! echo $VERS `basename \`pwd\`` `cat $1` | \
awk ' { version = $1; system = $2; release = $3; }\
END { printf "char version[] = \"SunOS Release %s (%s) #%d: ", release, system, version >> "vers.c";\
printf "%d\n", version > "version"; }'
--- 38,46 ----
echo '#include <sys/utsname.h>' > vers.c
echo >> vers.c
! SNAME=`basename \`pwd\``
! SLINE=`grep "^ident" ../conf/$SNAME | awk '{print $2}' | sed 's/"//g'`
! echo $VERS $SLINE `cat $1` | \
awk ' { version = $1; system = $2; release = $3; }\
END { printf "char version[] = \"SunOS Release %s (%s) #%d: ", release, system, version >> "vers.c";\
printf "%d\n", version > "version"; }'
***************
*** 32,34 ****
--- 54,61 ----
END { printf "struct utsname utsname =\n\t{ \"%s\", \"\", \"\", \"%s\", \"%s\", \"%s\" };\n\n", \
sysname, release, version, arch >> "vers.c" ; } '
+ # Create dummy variable containing identification for patched objects
+ #
+ (cd ../OBJ; echo 'static char *rcsid[] = {'; ls -l * | grep lrwx | \
+ cut -c46-500 | sed 's/^/ "\$Id: /' | \
+ sed 's/$/ \$",/'; echo '""};') >> vers.c
====================================================================
Example - here are the entries in OBJ for nfs* modules (3.1.3_U1):
-r--r--r-- 1 root staff 4620 Jan 4 1995 nfs_client.o
lrwxrwxrwx 1 root wheel 12 Sep 11 18:06 nfs_client.o-102177-02 -> nfs_client.o
-r--r--r-- 1 root staff 3036 Nov 13 1992 nfs_client.o.FCS
-r--r--r-- 1 root staff 960 Nov 13 1992 nfs_common.o
-r--r--r-- 1 root staff 5760 Nov 13 1992 nfs_dump.o
-r--r--r-- 1 root staff 5096 Nov 13 1992 nfs_export.o
-r--r--r-- 1 root staff 18900 Oct 13 1993 nfs_server.o
-r--r--r-- 1 root staff 16590 Oct 13 1993 nfs_subr.o
-r--r--r-- 1 root staff 14612 Nov 13 1992 nfs_vfsops.o
-r--r--r-- 1 root staff 41938 Jan 4 1995 nfs_vnodeops.o
lrwxrwxrwx 1 root wheel 14 Sep 11 18:06 nfs_vnodeops.o-102177-02 -> nfs_vnodeops.o
-r--r--r-- 1 root staff 41598 Oct 13 1993 nfs_vnodeops.o.FCS
-r--r--r-- 1 root staff 8112 Oct 13 1993 nfs_xdr.o