Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!mcvax!botter!ast
From: a...@cs.vu.nl (Andy Tanenbaum)
Newsgroups: comp.os.minix
Subject: Definitive MINIX 1.2 updates (Part 1 of 4)
Message-ID: <1562@botter.cs.vu.nl>
Date: Sun, 9-Aug-87 17:52:22 EDT
Article-I.D.: botter.1562
Posted: Sun Aug 9 17:52:22 1987
Date-Received: Tue, 11-Aug-87 00:45:00 EDT
Reply-To: a...@cs.vu.nl (Andy Tanenbaum)
Distribution: world
Organization: VU Informatica, Amsterdam
Lines: 474
Here is a summary of the changes to the definitive MINIX 1.2 release.
This message supercedes the earlier, preliminary posting. The main
changes to 1.2 are:
1. Various bug fixes. These are given in the files of this archive.
To install the fixes, use Erik Baalbergen's fix program as follows:
fix oldfile difflist >newfile
The only exception is crypt.c, which is included in its entirety, since
the new file is shorter than the diff listing.
2. A new shell. This was posted recently.
3. A considerably improved compiler. Information about obtaining it will
be posted when the compiler distribution itself is ready.
4. New hard disk drivers for the XT and AT. These were posted recently.
5. A number of new files. These are listed below. Most of these have already
been posted.
New file: commands/cpdir.c
New file: commands/diff.c
New file: commands/du.c
New file: commands/expr.c
New file: commands/fdisk.c
New file: commands/find.c
New file: commands/fix.c
New file: commands/more.c
New file: commands/printenv.c
New file: commands/readfs.c
New file: commands/test.c
New file: commands/uudecode.c
New file: commands/uuencode.c
New file: commands/C86/commands.C86
New file: commands/PCIX/makefile
New file: doc/man_pages
New file: fs/PCIX/makefile
New file: kernel/PCIX/makefile
New file: lib/ctime.c
New file: lib/popen.c
New file: lib/puts.c
New file: lib/qsort.c
New file: lib/system.c
New file: lib/PCIX/crtso.s
New file: lib/PCIX/end.s
New file: lib/PCIX/head.s
New file: lib/PCIX/setjmp.s
New file: mm/PCIX/makefile
New file: mm/C86/batch.a
New file: test/PCIX/makefile
New file: tools/proto.at.disk4
New file: tools/proto.at.disk5
New file: tools/proto.at.disk6
New file: tools/proto.at.usr
New file: tools/proto.disk9
New file: tools/message
New file: tools/profile
New file: tools/rc
New file: tools/PCIX/makefile
New file: tools/C86/batfiles.a
Here is a top-level listing (i.e. ls -l * in the minix directory)
---------------------- List of commands ----------------------
total 783
drwxr-xr-x 2 ast 48 Aug 8 17:06 C86
drwxr-xr-x 2 ast 48 Aug 8 17:06 MINIX
drwxr-xr-x 2 ast 48 Aug 8 17:06 PCIX
-rw-r--r-- 1 ast 10506 Aug 7 17:46 ar.c
-rw-r--r-- 1 ast 622 Aug 7 17:46 basename.c
-rw-r--r-- 1 ast 7998 Aug 7 17:46 cal.c
-rw-r--r-- 1 ast 1406 Aug 7 17:46 cat.c
-rw-r--r-- 1 ast 10899 Aug 7 17:46 cc.c
-rw-r--r-- 1 ast 2686 Aug 7 17:46 chmem.c
-rw-r--r-- 1 ast 733 Aug 7 17:46 chmod.c
-rw-r--r-- 1 ast 725 Aug 7 17:46 chown.c
-rw-r--r-- 1 ast 127 Aug 7 17:46 clr.c
-rw-r--r-- 1 ast 2220 Aug 7 17:46 cmp.c
-rw-r--r-- 1 ast 3433 Aug 7 17:46 comm.c
-rw-r--r-- 1 ast 2891 Aug 7 17:46 cp.c
-rw-r--r-- 1 ast 3619 Aug 7 17:46 cpdir.c
-rw-r--r-- 1 ast 3081 Aug 7 17:46 date.c
-rw-r--r-- 1 ast 5746 Aug 7 17:46 dd.c
-rw-r--r-- 1 ast 2979 Aug 7 17:46 df.c
-rw-r--r-- 1 ast 5385 Aug 7 17:46 diff.c
-rw-r--r-- 1 ast 20170 Aug 7 17:46 dosread.c
-rw-r--r-- 1 ast 4363 Aug 7 17:46 du.c
-rw-r--r-- 1 ast 723 Aug 7 17:46 echo.c
-rw-r--r-- 1 ast 2763 Aug 7 17:46 expr.c
-rw-r--r-- 1 ast 9890 Aug 7 17:46 fdisk.c
-rw-r--r-- 1 ast 12314 Aug 7 17:46 find.c
-rw-r--r-- 1 ast 3506 Aug 7 17:46 fix.c
-rw-r--r-- 1 ast 244 Aug 7 17:46 getlf.c
-rw-r--r-- 1 ast 2794 Aug 7 17:46 grep.c
-rw-r--r-- 1 ast 3232 Aug 7 17:46 gres.c
-rw-r--r-- 1 ast 1265 Aug 7 17:46 head.c
-rw-r--r-- 1 ast 553 Aug 7 17:46 kill.c
-rw-r--r-- 1 ast 4005 Aug 7 17:46 libpack.c
-rw-r--r-- 1 ast 1854 Aug 7 17:46 libupack.c
-rw-r--r-- 1 ast 1082 Aug 7 17:46 ln.c
-rw-r--r-- 1 ast 1211 Aug 7 17:46 login.c
-rw-r--r-- 1 ast 1647 Aug 7 17:46 lpr.c
-rw-r--r-- 1 ast 12924 Aug 7 17:46 ls.c
-rw-r--r-- 1 ast 51610 Aug 7 17:46 make.c
-rw-r--r-- 1 ast 931 Aug 7 17:46 makefile
drwxr-xr-x 2 ast 80 Aug 8 17:05 mined
-rw-r--r-- 1 ast 1319 Aug 7 17:46 mkdir.c
-rw-r--r-- 1 ast 25928 Aug 7 17:46 mkfs.c
-rw-r--r-- 1 ast 739 Aug 7 17:46 mknod.c
-rw-r--r-- 1 ast 4532 Aug 7 17:46 more.c
-rw-r--r-- 1 ast 613 Aug 7 17:46 mount.c
-rw-r--r-- 1 ast 3151 Aug 7 17:46 mv.c
-rw-r--r-- 1 ast 5193 Aug 7 17:46 od.c
-rw-r--r-- 1 ast 2384 Aug 7 17:46 passwd.c
-rw-r--r-- 1 ast 6562 Aug 7 17:46 pr.c
-rw-r--r-- 1 ast 190 Aug 7 17:46 printenv.c
-rw-r--r-- 1 ast 1635 Aug 7 17:46 pwd.c
-rw-r--r-- 1 ast 14451 Aug 7 17:46 readfs.c
-rw-r--r-- 1 ast 1450 Aug 7 17:46 rev.c
-rw-r--r-- 1 ast 2943 Aug 7 17:46 rm.c
-rw-r--r-- 1 ast 3002 Aug 7 17:46 rmdir.c
-rw-r--r-- 1 ast 20260 Aug 7 17:46 roff.c
-rwxr-xr-x 1 ast 88 Aug 7 17:46 run
drwxr-xr-x 2 ast 224 Aug 9 22:11 sh
-rw-r--r-- 1 ast 1254 Aug 7 17:46 shar.c
-rw-r--r-- 1 ast 1520 Aug 7 17:46 size.c
-rw-r--r-- 1 ast 427 Aug 7 17:46 sleep.c
-rw-r--r-- 1 ast 31388 Aug 7 17:46 sort.c
-rw-r--r-- 1 ast 1977 Aug 7 17:46 split.c
-rw-r--r-- 1 ast 2729 Aug 7 17:46 stty.c
-rw-r--r-- 1 ast 1124 Aug 7 17:46 su.c
-rw-r--r-- 1 ast 1724 Aug 7 17:46 sum.c
-rw-r--r-- 1 ast 140 Aug 7 17:46 sync.c
-rw-r--r-- 1 ast 4267 Aug 7 17:46 tail.c
-rw-r--r-- 1 ast 9378 Aug 7 17:46 tar.c
-rw-r--r-- 1 ast 1172 Aug 7 17:46 tee.c
-rw-r--r-- 1 ast 4115 Aug 7 17:46 test.c
-rw-r--r-- 1 ast 2643 Aug 7 17:46 time.c
-rw-r--r-- 1 ast 1255 Aug 7 17:46 touch.c
-rw-r--r-- 1 ast 3267 Aug 7 17:46 tr.c
-rw-r--r-- 1 ast 420 Aug 7 17:46 umount.c
-rw-r--r-- 1 ast 3263 Aug 7 17:46 uniq.c
-rw-r--r-- 1 ast 416 Aug 7 17:46 update.c
-rw-r--r-- 1 ast 3393 Aug 7 17:46 uudecode.c
-rw-r--r-- 1 ast 1822 Aug 7 17:46 uuencode.c
-rw-r--r-- 1 ast 2920 Aug 7 17:46 wc.c
---------------------- List of doc ----------------------
total 51
-rw-r--r-- 1 ast 17667 Aug 7 21:01 READ_ME
-rw-r--r-- 1 ast 8099 Aug 7 21:01 man_pages
---------------------- List of fs ----------------------
total 327
drwxr-xr-x 2 ast 80 Aug 8 17:11 C86
drwxr-xr-x 2 ast 48 Aug 8 17:11 MINIX
drwxr-xr-x 2 ast 48 Aug 8 21:38 PCIX
-rw-r--r-- 1 ast 2988 Aug 7 21:01 buf.h
-rw-r--r-- 1 ast 10862 Aug 7 21:01 cache.c
-rw-r--r-- 1 ast 2819 Aug 7 21:01 const.h
-rw-r--r-- 1 ast 273 Aug 7 21:01 dev.h
-rw-r--r-- 1 ast 6539 Aug 7 21:01 device.c
-rw-r--r-- 1 ast 474 Aug 7 21:01 file.h
-rw-r--r-- 1 ast 3225 Aug 7 21:01 filedes.c
-rw-r--r-- 1 ast 1431 Aug 7 21:01 fproc.h
-rw-r--r-- 1 ast 1013 Aug 7 21:01 glo.h
-rw-r--r-- 1 ast 7849 Aug 7 21:01 inode.c
-rw-r--r-- 1 ast 1943 Aug 7 21:01 inode.h
-rw-r--r-- 1 ast 5520 Aug 7 21:01 link.c
-rw-r--r-- 1 ast 10212 Aug 7 21:01 main.c
-rw-r--r-- 1 ast 3900 Aug 7 21:01 makefile
-rw-r--r-- 1 ast 7360 Aug 7 21:01 misc.c
-rw-r--r-- 1 ast 6271 Aug 7 21:01 mount.c
-rw-r--r-- 1 ast 9420 Aug 7 21:02 open.c
-rw-r--r-- 1 ast 1531 Aug 7 21:01 param.h
-rw-r--r-- 1 ast 10609 Aug 7 21:02 path.c
-rw-r--r-- 1 ast 8735 Aug 7 21:02 pipe.c
-rw-r--r-- 1 ast 5867 Aug 7 21:02 protect.c
-rw-r--r-- 1 ast 1441 Aug 7 21:02 putc.c
-rw-r--r-- 1 ast 12153 Aug 7 21:02 read.c
-rw-r--r-- 1 ast 5397 Aug 7 21:02 stadir.c
-rw-r--r-- 1 ast 8905 Aug 7 21:02 super.c
-rw-r--r-- 1 ast 2080 Aug 7 21:01 super.h
-rw-r--r-- 1 ast 4110 Aug 7 21:02 table.c
-rw-r--r-- 1 ast 2546 Aug 7 21:02 time.c
-rw-r--r-- 1 ast 711 Aug 7 21:01 type.h
-rw-r--r-- 1 ast 5382 Aug 7 21:02 utility.c
-rw-r--r-- 1 ast 7355 Aug 7 21:02 write.c
---------------------- List of h ----------------------
total 43
-rw-r--r-- 1 ast 1597 Aug 7 21:02 callnr.h
-rw-r--r-- 1 ast 5341 Aug 7 21:02 com.h
-rw-r--r-- 1 ast 4021 Aug 7 21:02 const.h
-rw-r--r-- 1 ast 2191 Aug 7 21:02 error.h
-rw-r--r-- 1 ast 1022 Aug 7 21:02 sgtty.h
-rw-r--r-- 1 ast 1151 Aug 7 21:02 signal.h
-rw-r--r-- 1 ast 861 Aug 7 21:02 stat.h
-rw-r--r-- 1 ast 3888 Aug 7 21:02 type.h
---------------------- List of include ----------------------
total 22
-rw-r--r-- 1 ast 59 Aug 7 21:02 blocksize.h
-rw-r--r-- 1 ast 673 Aug 7 21:02 ctype.h
-rw-r--r-- 1 ast 1133 Aug 7 21:02 errno.h
-rw-r--r-- 1 ast 57 Aug 7 21:02 grp.h
-rw-r--r-- 1 ast 295 Aug 7 21:02 lib.h
-rw-r--r-- 1 ast 128 Aug 7 21:02 pwd.h
-rw-r--r-- 1 ast 634 Aug 7 21:02 regexp.h
-rw-r--r-- 1 ast 46 Aug 7 21:02 setjmp.h
-rw-r--r-- 1 ast 1022 Aug 7 21:02 sgtty.h
-rw-r--r-- 1 ast 1151 Aug 7 21:02 signal.h
-rw-r--r-- 1 ast 861 Aug 7 21:02 stat.h
-rw-r--r-- 1 ast 1195 Aug 7 21:02 stdio.h
---------------------- List of kernel ----------------------
total 580
drwxr-xr-x 2 ast 112 Aug 8 21:24 C86
drwxr-xr-x 2 ast 48 Aug 8 21:24 MINIX
drwxr-xr-x 2 ast 48 Aug 8 21:24 PCIX
-rw-r--r-- 1 ast 15859 Aug 7 21:02 at_wini.c
-rw-r--r-- 1 ast 8871 Aug 7 21:02 clock.c
-rw-r--r-- 1 ast 2634 Aug 7 21:02 const.h
-rw-r--r-- 1 ast 3583 Aug 7 21:02 dmp.c
-rw-r--r-- 1 ast 25932 Aug 7 21:02 floppy.c
-rw-r--r-- 1 ast 832 Aug 7 21:02 glo.h
-rw-r--r-- 1 ast 18697 Aug 7 21:02 klib88.s
-rw-r--r-- 1 ast 8871 Aug 7 21:02 main.c
-rw-r--r-- 1 ast 2057 Aug 7 21:02 makefile
-rw-r--r-- 1 ast 4706 Aug 7 21:02 memory.c
-rw-r--r-- 1 ast 10719 Aug 7 21:02 mpx88.s
-rw-r--r-- 1 ast 9903 Aug 7 21:02 printer.c
-rw-r--r-- 1 ast 13068 Aug 7 21:02 proc.c
-rw-r--r-- 1 ast 2253 Aug 7 21:02 proc.h
-rw-r--r-- 1 ast 18953 Aug 7 21:02 system.c
-rw-r--r-- 1 ast 1594 Aug 7 21:02 table.c
-rw-r--r-- 1 ast 48579 Aug 7 21:02 tty.c
-rw-r--r-- 1 ast 664 Aug 7 21:02 type.h
-rw-r--r-- 1 ast 15859 Aug 7 21:02 wini.c
-rw-r--r-- 1 ast 48920 Aug 7 21:02 x.c
-rw-r--r-- 1 ast 26289 Aug 7 21:02 xt_wini.c
---------------------- List of lib ----------------------
total 273
drwxr-xr-x 2 ast 208 Aug 8 21:36 C86
drwxr-xr-x 2 ast 96 Aug 8 21:36 MINIX
drwxr-xr-x 2 ast 96 Aug 8 22:18 PCIX
-rw-r--r-- 1 ast 24 Aug 7 21:02 abort.c
-rw-r--r-- 1 ast 35 Aug 7 21:02 abs.c
-rw-r--r-- 1 ast 127 Aug 7 21:02 access.c
-rw-r--r-- 1 ast 141 Aug 7 21:02 alarm.c
-rw-r--r-- 1 ast 1052 Aug 7 21:02 atoi.c
-rw-r--r-- 1 ast 319 Aug 7 21:02 atol.c
-rw-r--r-- 1 ast 116 Aug 7 21:02 bcopy.c
-rw-r--r-- 1 ast 476 Aug 7 21:02 brk.c
-rw-r--r-- 1 ast 139 Aug 7 21:02 brk2.c
-rw-r--r-- 1 ast 53 Aug 7 21:02 brksize.s
-rw-r--r-- 1 ast 2087 Aug 7 21:02 call.c
-rw-r--r-- 1 ast 798 Aug 7 21:02 catchsig.s
-rw-r--r-- 1 ast 106 Aug 7 21:02 chdir.c
-rw-r--r-- 1 ast 125 Aug 7 21:02 chmod.c
-rw-r--r-- 1 ast 171 Aug 7 21:02 chown.c
-rw-r--r-- 1 ast 108 Aug 7 21:02 chroot.c
-rw-r--r-- 1 ast 153 Aug 7 21:02 cleanup.c
-rw-r--r-- 1 ast 128 Aug 7 21:02 close.c
-rw-r--r-- 1 ast 124 Aug 7 21:02 creat.c
-rw-r--r-- 1 ast 598 Aug 7 21:02 crtso.s
-rw-r--r-- 1 ast 6662 Aug 7 21:02 crypt.c
-rw-r--r-- 1 ast 1241 Aug 7 21:02 csv.s
-rw-r--r-- 1 ast 3629 Aug 7 21:02 ctime.c
-rw-r--r-- 1 ast 620 Aug 7 21:02 ctype.c
-rw-r--r-- 1 ast 3279 Aug 7 21:02 doprintf.c
-rw-r--r-- 1 ast 123 Aug 7 21:02 dup.c
-rw-r--r-- 1 ast 141 Aug 7 21:02 dup2.c
-rw-r--r-- 1 ast 103 Aug 7 21:02 end.s
-rw-r--r-- 1 ast 2299 Aug 7 21:02 exec.c
-rw-r--r-- 1 ast 137 Aug 7 21:02 exit.c
-rw-r--r-- 1 ast 314 Aug 7 21:02 fclose.c
-rw-r--r-- 1 ast 367 Aug 7 21:02 fflush.c
-rw-r--r-- 1 ast 316 Aug 7 21:02 fgets.c
-rw-r--r-- 1 ast 903 Aug 7 21:02 fopen.c
-rw-r--r-- 1 ast 114 Aug 7 21:02 fork.c
-rw-r--r-- 1 ast 320 Aug 7 21:02 fprintf.c
-rw-r--r-- 1 ast 113 Aug 7 21:02 fputs.c
-rw-r--r-- 1 ast 361 Aug 7 21:02 fread.c
-rw-r--r-- 1 ast 186 Aug 7 21:02 freopen.c
-rw-r--r-- 1 ast 873 Aug 7 21:02 fseek.c
-rw-r--r-- 1 ast 167 Aug 7 21:02 fstat.c
-rw-r--r-- 1 ast 418 Aug 7 21:02 ftell.c
-rw-r--r-- 1 ast 326 Aug 7 21:02 fwrite.c
-rw-r--r-- 1 ast 589 Aug 7 21:02 getc.c
-rw-r--r-- 1 ast 183 Aug 7 21:02 getegid.c
-rw-r--r-- 1 ast 255 Aug 7 21:02 getenv.c
-rw-r--r-- 1 ast 183 Aug 7 21:02 geteuid.c
-rw-r--r-- 1 ast 144 Aug 7 21:02 getgid.c
-rw-r--r-- 1 ast 2034 Aug 7 21:02 getgrent.c
-rw-r--r-- 1 ast 408 Aug 7 21:02 getpass.c
-rw-r--r-- 1 ast 118 Aug 7 21:02 getpid.c
-rw-r--r-- 1 ast 1745 Aug 7 21:02 getpwent.c
-rw-r--r-- 1 ast 251 Aug 7 21:02 gets.c
-rw-r--r-- 1 ast 144 Aug 7 21:02 getuid.c
-rw-r--r-- 1 ast 1000 Aug 7 21:02 getutil.s
-rw-r--r-- 1 ast 478 Aug 7 21:02 head.s
-rw-r--r-- 1 ast 113 Aug 7 21:02 index.c
-rw-r--r-- 1 ast 1521 Aug 7 21:02 ioctl.c
-rw-r--r-- 1 ast 161 Aug 7 21:02 isatty.c
-rw-r--r-- 1 ast 438 Aug 7 21:02 itoa.c
-rw-r--r-- 1 ast 216 Aug 7 21:02 kill.c
-rw-r--r-- 1 ast 157 Aug 7 21:02 link.c
-rw-r--r-- 1 ast 272 Aug 7 21:02 lseek.c
-rw-r--r-- 1 ast 2350 Aug 7 21:02 malloc.c
-rw-r--r-- 1 ast 59 Aug 7 21:02 message.c
-rw-r--r-- 1 ast 171 Aug 7 21:02 mknod.c
-rw-r--r-- 1 ast 420 Aug 7 21:02 mktemp.c
-rw-r--r-- 1 ast 192 Aug 7 21:02 mount.c
-rw-r--r-- 1 ast 122 Aug 7 21:02 open.c
-rw-r--r-- 1 ast 116 Aug 7 21:02 pause.c
-rw-r--r-- 1 ast 1449 Aug 7 21:02 perror.c
-rw-r--r-- 1 ast 226 Aug 7 21:02 pipe.c
-rw-r--r-- 1 ast 1025 Aug 7 21:02 popen.c
-rw-r--r-- 1 ast 371 Aug 7 21:02 printdat.c
-rw-r--r-- 1 ast 2177 Aug 7 21:02 printk.c
-rw-r--r-- 1 ast 1157 Aug 7 21:02 prints.c
-rw-r--r-- 1 ast 657 Aug 7 21:02 putc.c
-rw-r--r-- 1 ast 117 Aug 7 21:02 puts.c
-rw-r--r-- 1 ast 2820 Aug 7 21:02 qsort.c
-rw-r--r-- 1 ast 124 Aug 7 21:02 rand.c
-rw-r--r-- 1 ast 190 Aug 7 21:02 read.c
-rw-r--r-- 1 ast 27654 Aug 7 21:02 regexp.c
-rw-r--r-- 1 ast 2121 Aug 7 21:02 regsub.c
-rw-r--r-- 1 ast 156 Aug 7 21:02 rindex.c
-rw-r--r-- 1 ast 1640 Aug 7 21:02 run
-rw-r--r-- 1 ast 5869 Aug 7 21:02 scanf.c
-rw-r--r-- 1 ast 776 Aug 7 21:02 sendrec.s
-rw-r--r-- 1 ast 310 Aug 7 21:02 setbuf.c
-rw-r--r-- 1 ast 132 Aug 7 21:02 setgid.c
-rw-r--r-- 1 ast 451 Aug 7 21:02 setjmp.s
-rw-r--r-- 1 ast 132 Aug 7 21:02 setuid.c
-rw-r--r-- 1 ast 838 Aug 7 21:02 signal.c
-rw-r--r-- 1 ast 257 Aug 7 21:02 sleep.c
-rw-r--r-- 1 ast 305 Aug 7 21:02 sprintf.c
-rw-r--r-- 1 ast 175 Aug 7 21:02 stat.c
-rw-r--r-- 1 ast 211 Aug 7 21:02 stb.c
-rw-r--r-- 1 ast 84 Aug 7 21:02 stderr.c
-rw-r--r-- 1 ast 111 Aug 7 21:02 stime.c
-rw-r--r-- 1 ast 267 Aug 7 21:02 strcat.c
-rw-r--r-- 1 ast 167 Aug 7 21:02 strcmp.c
-rw-r--r-- 1 ast 159 Aug 7 21:02 strcpy.c
-rw-r--r-- 1 ast 124 Aug 7 21:02 strlen.c
-rw-r--r-- 1 ast 362 Aug 7 21:02 strncat.c
-rw-r--r-- 1 ast 218 Aug 7 21:02 strncmp.c
-rw-r--r-- 1 ast 226 Aug 7 21:02 strncpy.c
-rw-r--r-- 1 ast 114 Aug 7 21:02 sync.c
-rw-r--r-- 1 ast 3288 Aug 7 21:02 syslib.c
-rw-r--r-- 1 ast 386 Aug 7 21:02 system.c
-rw-r--r-- 1 ast 269 Aug 7 21:02 time.c
-rw-r--r-- 1 ast 277 Aug 7 21:02 times.c
-rw-r--r-- 1 ast 148 Aug 7 21:02 umask.c
-rw-r--r-- 1 ast 107 Aug 7 21:02 umount.c
-rw-r--r-- 1 ast 297 Aug 7 21:02 ungetc.c
-rw-r--r-- 1 ast 107 Aug 7 21:02 unlink.c
-rw-r--r-- 1 ast 198 Aug 7 21:02 utime.c
-rw-r--r-- 1 ast 173 Aug 7 21:02 wait.c
-rw-r--r-- 1 ast 165 Aug 7 21:02 write.c
---------------------- List of mm ----------------------
total 158
drwxr-xr-x 2 ast 96 Aug 8 21:28 C86
drwxr-xr-x 2 ast 48 Aug 8 21:27 MINIX
drwxr-xr-x 2 ast 48 Aug 8 22:16 PCIX
-rw-r--r-- 1 ast 7852 Aug 7 21:02 alloc.c
-rw-r--r-- 1 ast 7215 Aug 7 21:02 break.c
-rw-r--r-- 1 ast 639 Aug 7 21:02 const.h
-rw-r--r-- 1 ast 13602 Aug 7 21:03 exec.c
-rw-r--r-- 1 ast 9343 Aug 7 21:03 forkexit.c
-rw-r--r-- 1 ast 1572 Aug 7 21:03 getset.c
-rw-r--r-- 1 ast 801 Aug 7 21:02 glo.h
-rw-r--r-- 1 ast 7464 Aug 7 21:03 main.c
-rw-r--r-- 1 ast 1536 Aug 7 21:02 makefile
-rw-r--r-- 1 ast 1661 Aug 7 21:02 mproc.h
-rw-r--r-- 1 ast 677 Aug 7 21:02 param.h
-rw-r--r-- 1 ast 1487 Aug 7 21:03 putc.c
-rw-r--r-- 1 ast 13497 Aug 7 21:03 signal.c
-rw-r--r-- 1 ast 2734 Aug 7 21:03 table.c
-rw-r--r-- 1 ast 238 Aug 7 21:02 type.h
-rw-r--r-- 1 ast 4182 Aug 7 21:03 utility.c
---------------------- List of pc_simulator ----------------------
total 746
-rwxr-xr-x 1 ast 73648 Dec 18 1986 88
-rw-r--r-- 1 ast 23483 Dec 18 1986 88.c
-rw-r--r-- 1 ast 4415 Dec 18 1986 88.h
-rw-r--r-- 1 ast 402 Dec 18 1986 Makefile
-rw-r--r-- 1 ast 13228 Dec 18 1986 READ_ME
-rw-r--r-- 1 ast 28894 Dec 18 1986 adr.c
-rw-r--r-- 1 ast 8570 Dec 18 1986 aux.c
-rw-r--r-- 1 ast 4203 Dec 18 1986 cond.c
-rw-r--r-- 1 ast 7231 Dec 18 1986 dump.c
-rw-r--r-- 1 ast 1646 Dec 18 1986 dump.h
-rw-r--r-- 1 ast 5343 Dec 18 1986 flags.c
-rw-r--r-- 1 ast 561 Dec 18 1986 hist.c
-rw-r--r-- 1 ast 116736 Dec 18 1986 image
-rw-r--r-- 1 ast 3460 Dec 18 1986 io.c
-rw-r--r-- 1 ast 5649 Dec 18 1986 log.disk.0
-rw-r--r-- 1 ast 3105 Dec 18 1986 log.ram
-rw-r--r-- 1 ast 3003 Dec 18 1986 macro.h
-rw-r--r-- 1 ast 5818 Dec 18 1986 port.c
-rw-r--r-- 1 ast 1316 Dec 18 1986 r.c
-rwxr-xr-x 1 ast 61440 Dec 18 1986 rootfs
-rwxr-xr-x 1 ast 49 Dec 18 1986 run
-rw-r--r-- 1 ast 1358 Dec 18 1986 run.output
-rw-r--r-- 1 ast 382 Dec 18 1986 table.c
-rw-r--r-- 1 ast 2079 Dec 18 1986 var.h
---------------------- List of test ----------------------
total 4
drwxr-xr-x 2 ast 32 Aug 8 21:38 C86
drwxr-xr-x 2 ast 48 Aug 8 21:41 MINIX
drwxr-xr-x 2 ast 48 Aug 8 21:39 PCIX
-rw-r--r-- 1 ast 254 Aug 8 21:39 makefile
---------------------- List of tools ----------------------
total 314
drwxr-xr-x 2 ast 272 Aug 8 21:51 C86
drwxr-xr-x 2 ast 48 Aug 8 21:51 MINIX
drwxr-xr-x 2 ast 48 Aug 8 21:50 PCIX
-rw-r--r-- 1 ast 7503 Aug 7 21:03 bootblok.s
-rw-r--r-- 1 ast 19650 Aug 7 21:03 build.c
-rw-r--r-- 1 ast 821 Aug 7 21:03 changemem
-rw-r--r-- 1 ast 46061 Aug 7 21:03 fsck.c
-rw-r--r-- 1 ast 3158 Aug 7 21:03 fsck1.s
-rw-r--r-- 1 ast 2884 Aug 7 21:03 init.c
-rw-r--r-- 1 ast 4148 Aug 7 21:03 makefile
-rw-r--r-- 1 ast 96 Aug 7 21:03 message
-rw-r--r-- 1 ast 25928 Aug 7 21:03 mkfs.c
-rw-r--r-- 1 ast 71 Aug 7 21:03 passwd
-rw-r--r-- 1 ast 190 Aug 7 21:03 profile
-rw-r--r-- 1 ast 899 Aug 7 21:03 proto.256.ram
-rw-r--r-- 1 ast 2314 Aug 7 21:03 proto.256.usr
-rw-r--r-- 1 ast 5410 Aug 7 21:03 proto.at.disk4
-rw-r--r-- 1 ast 2425 Aug 7 21:03 proto.at.disk5
-rw-r--r-- 1 ast 5617 Aug 7 21:03 proto.at.disk6
-rw-r--r-- 1 ast 934 Aug 7 21:03 proto.at.ram
-rw-r--r-- 1 ast 4886 Aug 7 21:03 proto.at.usr
-rw-r--r-- 1 ast 1443 Aug 7 21:03 proto.disk5
-rw-r--r-- 1 ast 2382 Aug 7 21:03 proto.disk6
-rw-r--r-- 1 ast 1556 Aug 7 21:03 proto.disk7
-rw-r--r-- 1 ast 3601 Aug 7 21:03 proto.disk8
-rw-r--r-- 1 ast 1254 Aug 7 21:03 proto.disk9
-rw-r--r-- 1 ast 1243 Aug 7 21:03 proto.ram
-rw-r--r-- 1 ast 2332 Aug 7 21:03 proto.user
-rw-r--r-- 1 ast 2290 Aug 7 21:03 proto.usr
-rw-r--r-- 1 ast 1245 Aug 7 21:03 r.c
-rw-r--r-- 1 ast 155 Aug 7 21:03 rc
-rw-r--r-- 1 ast 4 Aug 7 21:03 ttys
---------------------- List of vax ----------------------
total 190
-rw-r--r-- 1 ast 6858 Dec 18 1986 READ_ME
-rw-r--r-- 1 ast 3117 Dec 18 1986 client.c
-rw-r--r-- 1 ast 1627 Dec 18 1986 client.o
-rwxr-xr-x 1 ast 31939 Dec 18 1986 fs
-rw-r--r-- 1 ast 608 Dec 18 1986 makefile
-rw-r--r-- 1 ast 7796 Dec 18 1986 server.c
-rw-r--r-- 1 ast 5566 Dec 18 1986 server.o
-rwxr-xr-x 1 ast 7307 Dec 18 1986 startup
-rw-r--r-- 1 ast 972 Dec 18 1986 startup.c
-rw-r--r-- 1 ast 820 Dec 18 1986 startup.o
-rwxr-xr-x 1 ast 12161 Dec 18 1986 student
-rw-r--r-- 1 ast 5996 Dec 18 1986 student.c
-rw-r--r-- 1 ast 6697 Dec 18 1986 student.o
-rw-r--r-- 1 ast 459 Dec 18 1986 xsys.o
-rw-r--r-- 1 ast 1173 Dec 18 1986 xsys.s
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!mcvax!botter!ast
From: a...@cs.vu.nl (Andy Tanenbaum)
Newsgroups: comp.os.minix
Subject: Definitive MINIX 1.2 updates (Part 2 of 4)
Message-ID: <1563@botter.cs.vu.nl>
Date: Sun, 9-Aug-87 17:53:28 EDT
Article-I.D.: botter.1563
Posted: Sun Aug 9 17:53:28 1987
Date-Received: Tue, 11-Aug-87 00:45:22 EDT
Reply-To: a...@cs.vu.nl (Andy Tanenbaum)
Distribution: world
Organization: VU Informatica, Amsterdam
Lines: 1049
: This is a shar archive. Extract with sh, not csh.
: This archive ends with exit, so do not worry about trailing junk.
: --------------------------- cut here --------------------------
PATH=/bin:/usr/bin
echo Extracting \c\m\d\s\:\a\r\.\c
sed 's/^X//' > \c\m\d\s\:\a\r\.\c << '+ END-OF-FILE '\c\m\d\s\:\a\r\.\c
X244c244
X< ar_fd = open_archive(argv[2], (show_fl || pr_fl) ? READ : APPEND);
X---
X> ar_fd = open_archive(argv[2], (show_fl || pr_fl || ex_fl) ? READ : APPEND);
+ END-OF-FILE cmds:ar.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\a\r\.\c
set `sum \c\m\d\s\:\a\r\.\c`
sum=$1
case $sum in
26299) :;;
*) echo 'Bad sum in '\c\m\d\s\:\a\r\.\c >&2
esac
echo Extracting \c\m\d\s\:\b\a\s\e\n\a\m\e\.
sed 's/^X//' > \c\m\d\s\:\b\a\s\e\n\a\m\e\. << '+ END-OF-FILE '\c\m\d\s\:\b\a\s\e\n\a\m\e\.
X27c27
X< prints("%s \n",d);
X---
X> prints("%s\n",d);
X35,36c35,36
X< prints("%s \n",c);
X< }
X---
X> prints("%s\n",c);
X> }
+ END-OF-FILE cmds:basename.
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\b\a\s\e\n\a\m\e\.
set `sum \c\m\d\s\:\b\a\s\e\n\a\m\e\.`
sum=$1
case $sum in
07740) :;;
*) echo 'Bad sum in '\c\m\d\s\:\b\a\s\e\n\a\m\e\. >&2
esac
echo Extracting \c\m\d\s\:\c\a\t\.\c
sed 's/^X//' > \c\m\d\s\:\c\a\t\.\c << '+ END-OF-FILE '\c\m\d\s\:\c\a\t\.\c
X86c86
X< if (write(1, buffer, next - buffer) <= 0) quit();
X---
X> if (write(1, buffer, (int) (next - buffer)) <= 0) quit();
+ END-OF-FILE cmds:cat.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\c\a\t\.\c
set `sum \c\m\d\s\:\c\a\t\.\c`
sum=$1
case $sum in
13846) :;;
*) echo 'Bad sum in '\c\m\d\s\:\c\a\t\.\c >&2
esac
echo Extracting \c\m\d\s\:\c\p\.\c
sed 's/^X//' > \c\m\d\s\:\c\p\.\c << '+ END-OF-FILE '\c\m\d\s\:\c\p\.\c
X47a48
X> exit(0);
+ END-OF-FILE cmds:cp.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\c\p\.\c
set `sum \c\m\d\s\:\c\p\.\c`
sum=$1
case $sum in
31554) :;;
*) echo 'Bad sum in '\c\m\d\s\:\c\p\.\c >&2
esac
echo Extracting \c\m\d\s\:\d\f\.\c
sed 's/^X//' > \c\m\d\s\:\d\f\.\c << '+ END-OF-FILE '\c\m\d\s\:\d\f\.\c
X37d36
X< extern char *itoa();
X133a133
X> return(0);
X146a147
X> extern char *itoa();
+ END-OF-FILE cmds:df.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\d\f\.\c
set `sum \c\m\d\s\:\d\f\.\c`
sum=$1
case $sum in
26779) :;;
*) echo 'Bad sum in '\c\m\d\s\:\d\f\.\c >&2
esac
echo Extracting \c\m\d\s\:\d\o\s\r\e\a\d\.\c
sed 's/^X//' > \c\m\d\s\:\d\o\s\r\e\a\d\.\c << '+ END-OF-FILE '\c\m\d\s\:\d\o\s\r\e\a\d\.\c
X16c16
X< #define DRIVE "/dev/fdX"
X---
X> #define DRIVE "/dev/atX"
X186c186
X< print_string(TRUE, "Diskette is neither 360K nor 1.2M\n");
X---
X> print_string(TRUE, "Diskette is not DOS 2.0 360K or 1.2M\n");
X279c279
X< while (*pathname != '/' && *pathname && i < 11)
X---
X> while (*pathname != '/' && *pathname && i < 12)
X494,506c494,502
X< for (i = 0, ptr = name; i < 8 && *ptr != '.' && *ptr; i++)
X< entry->d_name[i] = *ptr++;
X< while (i < 8)
X< entry->d_name[i++] = ' ';
X< r = strlen(name);
X< while (r && name[r - 1] != '.')
X< r--;
X<
X< i = 0;
X< while (r && i < 3 && name[r])
X< entry->d_ext[i++] = name[r++];
X< while (i < 3)
X< entry->d_ext[i++] = ' ';
X---
X> bcopy(" ",&entry->d_name[0],11); /* clear entry */
X> for (i = 0, ptr = name; i < 8 && *ptr != '.' && *ptr; i++)
X> entry->d_name[i] = *ptr++;
X> while (*ptr != '.' && *ptr)
X> ptr++;
X> if (*ptr == '.')
X> ptr++;
X> for (i=0;i < 3 && *ptr; i++)
X> entry->d_ext[i] = *ptr++;
X584c580
X< day -= mon_len[i];
X---
X> day -= mon_len[i++];
X641c637
X< return (buffer - begin);
X---
X> return (int) (buffer - begin);
X819c815
X< write(2, buf, buf_ptr - buf);
X---
X> write(2, buf, (int) (buf_ptr - buf));
+ END-OF-FILE cmds:dosread.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\d\o\s\r\e\a\d\.\c
set `sum \c\m\d\s\:\d\o\s\r\e\a\d\.\c`
sum=$1
case $sum in
38592) :;;
*) echo 'Bad sum in '\c\m\d\s\:\d\o\s\r\e\a\d\.\c >&2
esac
echo Extracting \c\m\d\s\:\h\e\a\d\.\c
sed 's/^X//' > \c\m\d\s\:\h\e\a\d\.\c << '+ END-OF-FILE '\c\m\d\s\:\h\e\a\d\.\c
X1a2,3
X> /* change to use putc() instead of prints() -- Dean Long 3/7/87 */
X>
X8d9
X< char lbuf[256];
X43,44c44,47
X< else
X< do_file(n);
X---
X> else {
X> do_file(n);
X> fflush(stdout);
X> }
X48d50
X< fflush(stdout);
X57,58c59,70
X< /* Print the first 'n' lines of a file. */
X< while (n--) do_line();
X---
X> int c;
X>
X> /* Print the first 'n' lines of a file. */
X> while(n)
X> switch (c = getc(stdin)) {
X> case EOF :
X> return;
X> case '\n':
X> --n;
X> default :
X> putc((char)c, stdout);
X> }
X62,80c74,79
X< do_line()
X< {
X< /* Print one line. */
X<
X< char c, *cp;
X< cp = lbuf;
X< while ( (c = getc(stdin)) != '\n') *cp++ = c;
X< *cp++ = '\n';
X< *cp++ = 0;
X< prints("%s",lbuf);
X< }
X<
X<
X< usage()
X< {
X< std_err("Usage: head [-n] [file ...]\n");
X< exit(1);
X< }
X<
X---
X> usage()
X> {
X> std_err("Usage: head [-n] [file ...]\n");
X> exit(1);
X> }
X>
+ END-OF-FILE cmds:head.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\h\e\a\d\.\c
set `sum \c\m\d\s\:\h\e\a\d\.\c`
sum=$1
case $sum in
26082) :;;
*) echo 'Bad sum in '\c\m\d\s\:\h\e\a\d\.\c >&2
esac
echo Extracting \c\m\d\s\:\k\i\l\l\.\c
sed 's/^X//' > \c\m\d\s\:\k\i\l\l\.\c << '+ END-OF-FILE '\c\m\d\s\:\k\i\l\l\.\c
X33,35c33,35
X< prints("usage: kill pid\n");
X< exit(1);
X< }
X---
X> prints("Usage: kill pid\n");
X> exit(1);
X> }
+ END-OF-FILE cmds:kill.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\k\i\l\l\.\c
set `sum \c\m\d\s\:\k\i\l\l\.\c`
sum=$1
case $sum in
52732) :;;
*) echo 'Bad sum in '\c\m\d\s\:\k\i\l\l\.\c >&2
esac
echo Extracting \c\m\d\s\:\l\n\.\c
sed 's/^X//' > \c\m\d\s\:\l\n\.\c << '+ END-OF-FILE '\c\m\d\s\:\l\n\.\c
X11a12
X> char *last_comp();
+ END-OF-FILE cmds:ln.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\l\n\.\c
set `sum \c\m\d\s\:\l\n\.\c`
sum=$1
case $sum in
44606) :;;
*) echo 'Bad sum in '\c\m\d\s\:\l\n\.\c >&2
esac
echo Extracting \c\m\d\s\:\l\o\g\i\n\.\c
sed 's/^X//' > \c\m\d\s\:\l\o\g\i\n\.\c << '+ END-OF-FILE '\c\m\d\s\:\l\o\g\i\n\.\c
X55,57c55,57
X< execl(pwd->pw_shell, "-", 0);
X< }
X< execl("/bin/sh", "-", 0);
X---
X> execl(pwd->pw_shell, "-", (char *) 0);
X> }
X> execl("/bin/sh", "-", (char *) 0);
+ END-OF-FILE cmds:login.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\l\o\g\i\n\.\c
set `sum \c\m\d\s\:\l\o\g\i\n\.\c`
sum=$1
case $sum in
14607) :;;
*) echo 'Bad sum in '\c\m\d\s\:\l\o\g\i\n\.\c >&2
esac
echo Extracting \c\m\d\s\:\l\s\.\c
sed 's/^X//' > \c\m\d\s\:\l\s\.\c << '+ END-OF-FILE '\c\m\d\s\:\l\s\.\c
X359c359,366
X< fprintf(stdout, "%s\n",fp->name);
X---
X> m = 0;
X> p1 = fp->name;
X> while (*p1 != 0 && (m < DIRNAMELEN || *p1 == '/') ) {
X> fprintf(stdout, "%c", *p1);
X> m = (*p1 == '/' ? 0 : m + 1);
X> p1++;
X> }
X> fprintf(stdout, "\n");
+ END-OF-FILE cmds:ls.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\l\s\.\c
set `sum \c\m\d\s\:\l\s\.\c`
sum=$1
case $sum in
63056) :;;
*) echo 'Bad sum in '\c\m\d\s\:\l\s\.\c >&2
esac
echo Extracting \c\m\d\s\:\m\a\k\e\.\c
sed 's/^X//' > \c\m\d\s\:\m\a\k\e\.\c << '+ END-OF-FILE '\c\m\d\s\:\m\a\k\e\.\c
X153c153
X< /* sysV and MONIX and LATTICE */
X---
X> /* sysV and MINIX and LATTICE */
X1899c1899
X< execl(SHELL,"sh","-c",cmd,0);
X---
X> execl(SHELL, "sh", "-c", cmd, (char *) 0);
+ END-OF-FILE cmds:make.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\m\a\k\e\.\c
set `sum \c\m\d\s\:\m\a\k\e\.\c`
sum=$1
case $sum in
25797) :;;
*) echo 'Bad sum in '\c\m\d\s\:\m\a\k\e\.\c >&2
esac
echo Extracting \c\m\d\s\:\m\i\n\e\d\1\.\c
sed 's/^X//' > \c\m\d\s\:\m\i\n\e\d\1\.\c << '+ END-OF-FILE '\c\m\d\s\:\m\i\n\e\d\1\.\c
X533c533
X< execl("/bin/sh", "sh", "-i", 0);
X---
X> execl("/bin/sh", "sh", "-i", (char *) 0);
+ END-OF-FILE cmds:mined1.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\m\i\n\e\d\1\.\c
set `sum \c\m\d\s\:\m\i\n\e\d\1\.\c`
sum=$1
case $sum in
44548) :;;
*) echo 'Bad sum in '\c\m\d\s\:\m\i\n\e\d\1\.\c >&2
esac
echo Extracting \c\m\d\s\:\m\k\f\s\.\c
sed 's/^X//' > \c\m\d\s\:\m\k\f\s\.\c << '+ END-OF-FILE '\c\m\d\s\:\m\k\f\s\.\c
X5c5
X< * with blocksize = zonesize. During the course of action the
X---
X> * with blocksize = zonesize. During the course of time the
X10,12c10,12
X< * To compile this program for MS-DOS, say cc -DDOS mkfs.c diskio.asm
X< * To compile this program for UNIX, say cc -DUNIX mkfs.c
X< * To compile this program for MINIX, say cc mkfs.c
X---
X> * To compile this program for MS-DOS, use: cc -DDOS mkfs.c diskio.asm
X> * To compile this program for UNIX, use: cc -DUNIX mkfs.c
X> * To compile this program for MINIX, use: cc mkfs.c
X32a33,34
X> #undef major
X> #undef minor
X55d56
X< #define ZONE_MAP 3
X61c62
X< #define N_BLOCKS 32000 /* must be multiple of 8 */
X---
X> #define N_BLOCKS 32000 /* must be multiple of 8 */
X73,77c74,79
X< nrinodes, lct=1, disk, fd, print=0, file=0, override=0, simple=0;
X<
X< long current_time;
X< char zero[BLOCK_SIZE], *lastp;
X< char umap[(N_BLOCKS+8)/8]; /* bit map tells if block read yet */
X---
X> nrinodes, lct=1, disk, fd, print=0, file=0, override=0, simple=0, dflag;
X>
X> long current_time, bin_time;
X> char zero[BLOCK_SIZE], *lastp;
X> char umap[(N_BLOCKS+8)/8]; /* bit map tells if block read yet */
X> int zone_map = 3; /* where is zone map? (depends on # inodes) */
X86d87
X<
X106,108c107,118
X< /* process parameters and switches */
X<
X< current_time = time(0L);
X---
X>
X> /* Get two times, the current time and the mod time of the binary of
X> * mkfs itself. When the -d flag is used, the later time is put into
X> * the i_modtimes of all the files. This feature is useful when producing
X> * a set of file systems, and one wants all the times to be identical.
X> * First you set the time of the mkfs binary to what you want, then go.
X> */
X> current_time = time(0L); /* time mkfs is being run */
X> stat(argv[0], &statbuf);
X> bin_time = statbuf.st_mtime; /* time when mkfs binary was last modified */
X>
X> /* process parameters and switches */
X128c138,139
X< default :
X---
X> case 'd' : current_time = bin_time; dflag=1; break;
X> default :
X226c237,238
X< int i, inodeblks, initblks, initzones, nrzones;
X---
X> unsigned int i, inodeblks, initblks, initzones, nrzones, bs;
X> unsigned int map_size, bit_map_len, b_needed, b_allocated, residual;
X233,236c245,249
X< sup->s_ninodes = inodes;
X< sup->s_nzones = zones;
X< sup->s_imap_blocks = (inodes + (1<<BIT_MAP_SHIFT)-1) >> BIT_MAP_SHIFT;
X< sup->s_zmap_blocks = (zones + (1<<BIT_MAP_SHIFT)-1) >> BIT_MAP_SHIFT;
X---
X> bs = 1 << BIT_MAP_SHIFT;
X> sup->s_ninodes = inodes;
X> sup->s_nzones = zones;
X> sup->s_imap_blocks = (inodes + bs)/bs;
X> sup->s_zmap_blocks = (zones + bs - 1)/bs;
X261,266c274,313
X< insert_bit(ZONE_MAP, 0, 1); /* bit zero must always be allocated */
X< insert_bit(INODE_MAP, 0, 1); /* inode zero used by root-directory */
X<
X< /* Mark all bits beyond the end of the legal inodes/zones as allocated. */
X< insert_bit(ZONE_MAP,nrzones-initzones+1, 8*BLOCK_SIZE-(nrzones-initzones+1));
X< insert_bit(INODE_MAP, inodes+1, 8*BLOCK_SIZE - inodes - 1);
X---
X>
X> /* Mark all bits beyond the end of the legal inodes and zones as allocated.
X> * Unfortunately, the coding the bit maps is inconsistent. The rules are:
X> * For inodes: Every i-node occupies a bit map slot, even i-node 0
X> * The first i-node on the disk is i-node 1, not 0
X> * For zones: Zone map bit 0 is for the last i-node block on disk
X> * The first zone available goes with bit 1 in the map
X> *
X> * Thus for i-nodes, every i-node, starting at 0 occupies a bit map slot,
X> * but for zones, only those starting with the final i-node block occupy
X> * bit slots. This is inconsistent. In retrospect it would might have been
X> * simpler to have bit 0 of the zone map be zone 0 on the disk. Although
X> * this would have increased the zone bit map by a few dozen bits, it would
X> * have prevented a number of bugs in the early days. This is an example of
X> * what happens when one ignores the maxim: First make it work, then make
X> * it optimal. For both maps, 0 = available, 1 = in use.
X> */
X>
X> /* Mark bits beyond end of inodes as allocated. (Fails if >8192 inodes). */
X> map_size = 1 << BIT_MAP_SHIFT;
X> bit_map_len = nrinodes + 1; /* # bits needed in map */
X> residual = bit_map_len % (8 * BLOCK_SIZE);
X> if (residual == 0) residual = 8 * BLOCK_SIZE;
X> b_needed = (bit_map_len + map_size - 1 ) >> BIT_MAP_SHIFT;
X> zone_map += b_needed - 1; /* if imap > 1, adjust start of zone map */
X> insert_bit(INODE_MAP + b_needed - 1, residual, 8 * BLOCK_SIZE - residual);
X>
X> bit_map_len = nrzones - initzones + 1; /* # bits needed in map */
X> residual = bit_map_len % (8 * BLOCK_SIZE);
X> if (residual == 0) residual = 8 * BLOCK_SIZE;
X> b_needed = (bit_map_len + map_size - 1 ) >> BIT_MAP_SHIFT;
X> b_allocated = (nrzones + map_size - 1 ) >> BIT_MAP_SHIFT;
X> insert_bit(zone_map + b_needed - 1, residual, 8 * BLOCK_SIZE - residual);
X> if (b_needed != b_allocated) {
X> insert_bit(zone_map + b_allocated - 1, 0, map_size);
X> }
X>
X> insert_bit(zone_map, 0, 1); /* bit zero must always be allocated */
X> insert_bit(INODE_MAP, 0, 1); /* inode zero not used but must be allocated */
X>
X364a412
X> long timeval;
X375c423,424
X< if (ct) add_zone (inode, z, (long) j, file_time(f) );
X---
X> timeval = (dflag ? current_time : file_time(f) );
X> if (ct) add_zone (inode, z, (long) j, timeval );
X448c497,498
X< int b, off, blk[INTS_PER_BLOCK], indir, i;
X---
X> int b, off, indir, i;
X> zone_nr blk[NR_INDIRECTS];
X472,474c522,524
X< for (i = 0; i < INTS_PER_BLOCK; i++)
X< if (blk[i] == 0) {
X< blk[i] = z;
X---
X> for (i = 0; i < NR_INDIRECTS; i++)
X> if (blk[i] == 0) {
X> blk[i] = (zone_nr) z;
X555d604
X<
X559c608
X< insert_bit(ZONE_MAP, z - zoff, 1);
X---
X> insert_bit(zone_map, z - zoff, 1);
X571c620
X< char buf[BLOCK_SIZE];
X---
X> int buf[BLOCK_SIZE/sizeof(int)];
X575,576c624,625
X< w = i/8;
X< s = i % 8;
X---
X> w = i / (8*sizeof(int));
X> s = i % (8*sizeof(int));
X622c671
X< for (k = 0; k < MAX_TOKEN; k++) parse[k] = 0;
X---
X> for (k = 0; k < MAX_TOKENS; k++) parse[k] = 0;
X678c727
X< write (2, s, s0-s );
X---
X> write (2, s, (int)(s0-s) );
X829c878
X< if ((fd=creat(string,BWRITE)) == 0)
X---
X> if ((fd = creat(string,BWRITE)) == 0)
X1096a1146
X>
+ END-OF-FILE cmds:mkfs.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\m\k\f\s\.\c
set `sum \c\m\d\s\:\m\k\f\s\.\c`
sum=$1
case $sum in
34721) :;;
*) echo 'Bad sum in '\c\m\d\s\:\m\k\f\s\.\c >&2
esac
echo Extracting \c\m\d\s\:\m\v\.\c
sed 's/^X//' > \c\m\d\s\:\m\v\.\c << '+ END-OF-FILE '\c\m\d\s\:\m\v\.\c
X1c1,4
X< /* mv - move files Author: Adri Koppes */
X---
X> /* mv - move files Author: Adri Koppes
X> *
X> * 4/25/87 - J. Paradis Bug fixes for directory handling
X> */
X7c10
X< struct stat st;
X---
X> struct stat st, st1;
X26,37c29
X< if ((st.st_mode & S_IFMT) == S_IFDIR) {
X< if (!stat(argv[2], &st) && (st.st_mode & S_IFMT) == S_IFDIR) {
X< std_err ("mv: target ");
X< std_err (argv[2]);
X< std_err (" exists\n");
X< exit (1);
X< }
X< }
X< else {
X< setgid (getgid ());
X< setuid (getuid ());
X< }
X---
X>
X41,42d32
X< setgid (getgid ());
X< setuid (getuid ());
X67a58,68
X> char name[64];
X>
X> /* It's too dangerous to fool with "." or ".." ! */
X> if((strcmp(old, ".") == 0) || (strcmp(old, "..") == 0)) {
X> cant(old);
X> }
X>
X> /* Don't move a file to itself. */
X> if (stat(old, &st)==0 && stat(new, &st1)==0 && st.st_dev == st1.st_dev &&
X> st.st_ino == st1.st_ino)
X> cant(old);
X73c74
X< char name[64], *p, *rindex();
X---
X> char *p, *rindex();
X91c92,94
X< execl ("/bin/cp", "cp", old, new, 0);
X---
X> setgid (getgid ());
X> setuid (getuid ());
X> execl ("/bin/cp", "cp", old, new, (char *) 0);
X103,114c106,161
X< utime (new, &st.st_atime);
X< unlink(old);
X< }
X<
X< cant(name)
X< char *name;
X< {
X< std_err("mv: can't move ");
X< std_err (name);
X< std_err ("\n");
X< exit (1);
X< }
X---
X>
X> /* If this was a directory that we moved, then we have
X> ** to update its ".." entry (in case it was moved some-
X> ** where else in the tree...)
X> */
X> if ((st.st_mode & S_IFMT) == S_IFDIR) {
X> int i;
X> char parent[64], dotdot[64];
X>
X> strcpy(parent, new);
X>
X> /* Determine the name for the parent of
X> ** the new name by counting back until we
X> ** hit a '/' or the begining of the string
X> */
X>
X> for(i = (strlen(parent) - 1); i > 0; i--) {
X> if(parent[i] == '/') break;
X> }
X>
X> /* If there are no slashes, then the name is
X> ** in the current directory, so its parent
X> ** is ".". Otherwise, the parent is the name
X> ** up to the last slash.
X> */
X> if(i == 0) {
X> strcpy(parent, ".");
X> }
X> else {
X> /* null-terminate name at last slash */
X> parent[i] = '\0';
X> }
X>
X> /* Unlink the ".." entry */
X> strcpy(dotdot, new);
X> strcat(dotdot, "/..");
X> unlink(dotdot);
X>
X> /* Now link it to its parent */
X> link(parent, dotdot);
X> }
X>
X> utime (new, &st.st_atime);
X> unlink(old);
X> }
X>
X> cant(name)
X> char *name;
X> {
X> std_err("mv: can't move ");
X> std_err (name);
X> std_err ("\n");
X> exit (1);
X> }
X>
X>
+ END-OF-FILE cmds:mv.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\m\v\.\c
set `sum \c\m\d\s\:\m\v\.\c`
sum=$1
case $sum in
44861) :;;
*) echo 'Bad sum in '\c\m\d\s\:\m\v\.\c >&2
esac
echo Extracting \c\m\d\s\:\o\d\.\c
sed 's/^X//' > \c\m\d\s\:\o\d\.\c << '+ END-OF-FILE '\c\m\d\s\:\o\d\.\c
X26c26
X< if (*p == '-') {
X---
X> if (argc > 1 && *p == '-') {
X168,169c168,169
X< bdump(words, k, c)
X< int words[8];
X---
X> bdump(bytes, k, c)
X> char bytes[16];
X174,186c174,176
X< int c1, c2;
X<
X< i = 0;
X< if (linenr++ != 1) printf(" ");
X< while (i < k) {
X< c1 = words[i>>1] & 0377;
X< c2 = (words[i>>1]>>8) & 0377;
X< byte(c1, c);
X< i++;
X< if (i == k) {printf("\n"); return;}
X< byte(c2, c);
X< i++;
X< }
X---
X>
X> if (linenr++ != 1) printf(" ");
X> for (i = 0; i < k; i++) byte(bytes[i] & 0377, c);
+ END-OF-FILE cmds:od.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\o\d\.\c
set `sum \c\m\d\s\:\o\d\.\c`
sum=$1
case $sum in
27139) :;;
*) echo 'Bad sum in '\c\m\d\s\:\o\d\.\c >&2
esac
echo Extracting \c\m\d\s\:\p\a\s\s\w\d\.\c
sed 's/^X//' > \c\m\d\s\:\p\a\s\s\w\d\.\c << '+ END-OF-FILE '\c\m\d\s\:\p\a\s\s\w\d\.\c
X50a51,54
X> if (password[0] == '\0') {
X> std_err("password cannot be null\n");
X> exit(1);
X> }
+ END-OF-FILE cmds:passwd.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\p\a\s\s\w\d\.\c
set `sum \c\m\d\s\:\p\a\s\s\w\d\.\c`
sum=$1
case $sum in
08089) :;;
*) echo 'Bad sum in '\c\m\d\s\:\p\a\s\s\w\d\.\c >&2
esac
echo Extracting \c\m\d\s\:\p\r\.\c
sed 's/^X//' > \c\m\d\s\:\p\r\.\c << '+ END-OF-FILE '\c\m\d\s\:\p\r\.\c
X257,259c257,260
X< do {
X< putchar(c);
X< } while ((c = getc(filep)) != '\n' && c != EOF);
X---
X> while (c != '\n' && c != EOF) {
X> putchar(c);
X> c = getc(filep);
X> }
+ END-OF-FILE cmds:pr.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\p\r\.\c
set `sum \c\m\d\s\:\p\r\.\c`
sum=$1
case $sum in
02036) :;;
*) echo 'Bad sum in '\c\m\d\s\:\p\r\.\c >&2
esac
echo Extracting \c\m\d\s\:\p\w\d\.\c
sed 's/^X//' > \c\m\d\s\:\p\w\d\.\c << '+ END-OF-FILE '\c\m\d\s\:\p\w\d\.\c
X12c12,13
X< register char name[128], *n;
X---
X> register *n;
X> char name[128];
+ END-OF-FILE cmds:pwd.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\p\w\d\.\c
set `sum \c\m\d\s\:\p\w\d\.\c`
sum=$1
case $sum in
20465) :;;
*) echo 'Bad sum in '\c\m\d\s\:\p\w\d\.\c >&2
esac
echo Extracting \c\m\d\s\:\r\m\.\c
sed 's/^X//' > \c\m\d\s\:\r\m\.\c << '+ END-OF-FILE '\c\m\d\s\:\r\m\.\c
X107,109c107,109
X< stderr3 ("rm: remove ", name, " with mode ");
X< octal(s.st_mode & 0777);
X< std_err("? ");
X---
X> stderr3 ("rm: remove ", name, " (mode = ");
X> octal(s.st_mode & 0777);
X> std_err(") ? ");
X132,133c132,133
X< execl ("/bin/rmdir", "rmdir", name, 0);
X< execl ("/usr/bin/rmdir", "rmdir", name, 0);
X---
X> execl ("/bin/rmdir", "rmdir", name, (char*) 0);
X> execl ("/usr/bin/rmdir", "rmdir", name, (char*) 0);
+ END-OF-FILE cmds:rm.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\r\m\.\c
set `sum \c\m\d\s\:\r\m\.\c`
sum=$1
case $sum in
59181) :;;
*) echo 'Bad sum in '\c\m\d\s\:\r\m\.\c >&2
esac
echo Extracting \c\m\d\s\:\r\m\d\i\r\.\c
sed 's/^X//' > \c\m\d\s\:\r\m\d\i\r\.\c << '+ END-OF-FILE '\c\m\d\s\:\r\m\d\i\r\.\c
X1c1,3
X< /* rmdir - remove a directory Author: Adri Koppes */
X---
X> /* rmdir - remove a directory Author: Adri Koppes
X> * (modified by Paul Polderman)
X> */
X29a32,33
X> extern char *rindex();
X>
X37a42
X> register char *p;
X49,55c54,60
X< strcpy (dots, dirname);
X< while (dirname[fd])
X< if (dirname[fd++] == '/')
X< sl = fd;
X< dots[sl] = '\0';
X< if (access (dots, 2)) {
X< stderr2(dirname, " no permission\n");
X---
X> if (p = rindex(dirname, '/'))
X> p++;
X> else
X> p = dirname;
X>
X> if (strcmp(p, ".") == 0 || strcmp(p, "..") == 0) {
X> stderr2(dirname, " will not remove \".\" or \"..\"\n");
X59,61c64,71
X< stat ("", &cwd);
X< if ((s.st_ino == cwd.st_ino) && (s.st_dev == cwd.st_dev)) {
X< std_err ("rmdir: can't remove current directory\n");
X---
X>
X> strcpy (dots, dirname);
X> while (dirname[fd])
X> if (dirname[fd++] == '/')
X> sl = fd;
X> dots[sl] = '\0';
X> if (access (dots, 2)) {
X> stderr2(dirname, " no permission\n");
X65,67c75,77
X< if ((fd = open (dirname, 0)) < 0) {
X< stderr2("can't read ", dirname);
X< std_err("\n");
X---
X> stat ("", &cwd);
X> if ((s.st_ino == cwd.st_ino) && (s.st_dev == cwd.st_dev)) {
X> std_err ("rmdir: can't remove current directory\n");
X70a81,86
X> if ((fd = open (dirname, 0)) < 0) {
X> stderr2("can't read ", dirname);
X> std_err("\n");
X> error++;
X> return;
X> }
X81,86c97,106
X< strcat (dots, "/.");
X< unlink (dots);
X< strcat (dots, ".");
X< unlink (dots);
X< if (unlink (dirname)) {
X< stderr2("can't remove ", dirname);
X---
X> strcat (dots, "/..");
X> patch_path(dots);
X> for (p = dots; *p; p++) /* find end of dots */
X> ;
X> unlink(dots); /* dirname/.. */
X> *(p - 1) = '\0';
X> unlink(dots); /* dirname/. */
X> *(p - 3) = '\0';
X> if (unlink(dots)) { /* dirname */
X> stderr2("can't remove ", dots);
X99a120,148
X>
X> patch_path(dir)
X> char *dir; /* pathname ending with "/.." */
X> {
X> register char *p, *s;
X> struct stat pst, st;
X>
X> if (stat(dir, &pst) < 0)
X> return;
X> p = dir;
X> while (*p == '/') p++;
X> while (1) {
X> s = p; /* remember start of new pathname part */
X> while (*p && *p != '/')
X> p++; /* find next slash */
X> if (*p == '\0')
X> return; /* if end of pathname, return */
X>
X> /* check if this part of pathname == the original pathname */
X> *p = '\0';
X> stat(dir, &st);
X> if (st.st_ino == pst.st_ino && st.st_dev == pst.st_dev
X> && strcmp(s, "..") == 0)
X> return;
X> /* if not, try next part */
X> *p++ = '/';
X> while (*p == '/') p++;
X> }
X> }
+ END-OF-FILE cmds:rmdir.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\r\m\d\i\r\.\c
set `sum \c\m\d\s\:\r\m\d\i\r\.\c`
sum=$1
case $sum in
26410) :;;
*) echo 'Bad sum in '\c\m\d\s\:\r\m\d\i\r\.\c >&2
esac
echo Extracting \c\m\d\s\:\r\o\f\f\.\c
sed 's/^X//' > \c\m\d\s\:\r\o\f\f\.\c << '+ END-OF-FILE '\c\m\d\s\:\r\o\f\f\.\c
X1c1,16
X< /* roff - text justifier Author: George Sicherman */
X---
X> /* roff - text justifier Author: George L. Sicherman */
X>
X> /*
X> * roff - C version.
X> * the Colonel. 19 May 1983.
X> *
X> * Copyright 1983 by G. L. Sicherman.
X> * You may use and alter this software freely for noncommercial ends
X> * so long as you leave this message alone.
X> *
X> * Fix by Tim Maroney, 31 Dec 1984.
X> * .hc implemented, 8 Feb 1985.
X> * Fix to hyphenating with underlining, 12 Feb 1985.
X> * Fixes to long-line hang and .bp by Dave Tutelman, 30 Mar 1985.
X> * Fix to centering valve with long input lines, 4 May 1987.
X> */
X14,16c29,32
X< #define UNDERL 0200
X<
X< char cumbuf[BUFSIZ];
X---
X> #define UNDERL '\200'
X>
X> char cumbuf[BUFSIZ];
X>
X48d63
X< int center = 0;
X67d81
X<
X128,130c142,144
X< char *ttyname();
X<
X< /* This routine is not needed --
X---
X> /* This routine is not needed.
X> char *ttyname();
X>
X138c152
X< */
X---
X> * ------- end of mesg */
X145,147c159,162
X< if (center || !o_fi) {
X< if (assylen) writeline(0,1);
X< else blankline();
X---
X> if (o_ce || !o_fi) {
X> if (assylen) writeline(0,1);
X> else blankline();
X> if (o_ce) o_ce--;
X213,214d227
X< center=o_ce;
X< if (o_ce) o_ce--;
X227a241,244
X> * Tutelman's fix #1, modified by the Colonel.
X> */
X> if (!o_fi || o_ce) goto giveup;
X> /*
X242c259
X< if (*hc!=o_hc) continue;
X---
X> if ((*hc&~UNDERL)!=o_hc) continue;
X293c310
X< for (t=s; *s; s++) if (*s != o_hc) *t++ = *s;
X---
X> for (t=s; *s; s++) if ((*s&~UNDERL) != o_hc) *t++ = *s;
X307c324
X< while (*s) n += (o_hc != *s++);
X---
X> while (*s) n += (o_hc != (~UNDERL & *s++));
X372,373c389,393
X< if (s>0) o_bp=page_no-r;
X< else if (s<0) o_bp=page_no+r;
X---
X> /*
X> * Tutelman's fix #2 - the signs were reversed!
X> */
X> if (s>0) o_bp=page_no+r;
X> else if (s<0) o_bp=page_no-r;
X388,389c408,413
X< nread(&o_ce);
X< writebreak();
X---
X> /*
X> * Fix to centering. Set counter _after_ breaking! --G.L.S.
X> */
X> nread(&r);
X> writebreak();
X> o_ce = r;
X735c759
X< if (c==EOF || c=='\n') break;;
X---
X> if (c==EOF || c=='\n') break;
X836c860
X< if (center) for (j=0; j<(o_ll-assylen+1)/2; j++) spit(' ');
X---
X> if (o_ce) for (j=0; j<(o_ll-assylen+1)/2; j++) spit(' ');
X1085c1109,1112
X< c = *t;
X---
X> /*
X> * fix - last char translates to space.
X> */
X> c = *t? *t: ' ';
X1123,1125c1150
X< * strhas - does string have character?
X< * USG and BSD both have this in their libraries. Now, if
X< * they could just agree on the name of the function ...
X---
X> * strhas - does string have character? Allow UNDERL flag.
X1132c1157
X< for (; *p; p++) if (*p==c) return p;
X---
X> for (; *p; p++) if ((*p&~UNDERL)==c) return p;
+ END-OF-FILE cmds:roff.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\r\o\f\f\.\c
set `sum \c\m\d\s\:\r\o\f\f\.\c`
sum=$1
case $sum in
47876) :;;
*) echo 'Bad sum in '\c\m\d\s\:\r\o\f\f\.\c >&2
esac
echo Extracting \c\m\d\s\:\s\p\l\i\t\.\c
sed 's/^X//' > \c\m\d\s\:\s\p\l\i\t\.\c << '+ END-OF-FILE '\c\m\d\s\:\s\p\l\i\t\.\c
X66c66
X< if (write(fd, base, index-base) != index-base)
X---
X> if (write(fd,base,(int)(index-base)) != (int)(index-base))
X73c73
X< if (write(fd, base, index - base) != index - base) quit();
X---
X> if (write(fd, base, (int) (index-base)) != (int) (index-base)) quit();
+ END-OF-FILE cmds:split.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\s\p\l\i\t\.\c
set `sum \c\m\d\s\:\s\p\l\i\t\.\c`
sum=$1
case $sum in
15949) :;;
*) echo 'Bad sum in '\c\m\d\s\:\s\p\l\i\t\.\c >&2
esac
echo Extracting \c\m\d\s\:\t\a\r\.\c
sed 's/^X//' > \c\m\d\s\:\t\a\r\.\c << '+ END-OF-FILE '\c\m\d\s\:\t\a\r\.\c
X60a61,62
X> char path[NAME_SIZE];
X> char pathname[NAME_SIZE];
X111,112c113,116
X< for (i = 3; i < argc; i++)
X< add_file(argv[i]);
X---
X> for (i = 3; i < argc; i++) {
X> add_file(argv[i]);
X> path[0] = '\0';
X> }
X158,163c162,167
X< string_print(NIL_PTR, "linked to %s",
X< header.member.m_link);
X< else
X< string_print(NIL_PTR, "%d tape blocks", block_size());
X< print("\n");
X< skip_entry();
X---
X> string_print(NIL_PTR, "linked to %s\n",
X> header.member.m_link);
X> else {
X> string_print(NIL_PTR, "%d tape blocks\n", block_size());
X> skip_entry();
X> }
X248c252
X< execl(MKDIR, "mkdir", dir_name, 0);
X---
X> execl(MKDIR, "mkdir", dir_name, (char *) 0);
X281,283c285
X< char path[NAME_SIZE];
X<
X< char pathname[NAME_SIZE];
X---
X>
+ END-OF-FILE cmds:tar.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\t\a\r\.\c
set `sum \c\m\d\s\:\t\a\r\.\c`
sum=$1
case $sum in
45064) :;;
*) echo 'Bad sum in '\c\m\d\s\:\t\a\r\.\c >&2
esac
echo Extracting \c\m\d\s\:\w\c\.\c
sed 's/^X//' > \c\m\d\s\:\w\c\.\c << '+ END-OF-FILE '\c\m\d\s\:\w\c\.\c
X55c55
X< if (*cp++ == '-') {
X---
X> if (argc >1 && *cp++ == '-') {
+ END-OF-FILE cmds:wc.c
chmod 'u=rw,g=r,o=r' \c\m\d\s\:\w\c\.\c
set `sum \c\m\d\s\:\w\c\.\c`
sum=$1
case $sum in
34156) :;;
*) echo 'Bad sum in '\c\m\d\s\:\w\c\.\c >&2
esac
e2 m2 m
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!mcvax!botter!ast
From: a...@cs.vu.nl (Andy Tanenbaum)
Newsgroups: comp.os.minix
Subject: Definitive MINIX 1.2 updates (Part 3 of 4)
Message-ID: <1564@botter.cs.vu.nl>
Date: Sun, 9-Aug-87 17:55:13 EDT
Article-I.D.: botter.1564
Posted: Sun Aug 9 17:55:13 1987
Date-Received: Tue, 11-Aug-87 00:45:43 EDT
Reply-To: a...@cs.vu.nl (Andy Tanenbaum)
Distribution: world
Organization: VU Informatica, Amsterdam
Lines: 878
: This is a shar archive. Extract with sh, not csh.
: This archive ends with exit, so do not worry about trailing junk.
: --------------------------- cut here --------------------------
PATH=/bin:/usr/bin
echo Extracting \c\r\y\p\t\.\c
sed 's/^X//' > \c\r\y\p\t\.\c << '+ END-OF-FILE '\c\r\y\p\t\.\c
X/* From Andy Tanenbaum's book "Computer Networks",
X rewritten in C
X*/
X
Xstruct block {
X unsigned char b_data[64];
X};
X
Xstruct ordering {
X unsigned char o_data[64];
X};
X
Xstatic struct block key;
X
Xstatic struct ordering InitialTr = {
X 58,50,42,34,26,18,10, 2,60,52,44,36,28,20,12, 4,
X 62,54,46,38,30,22,14, 6,64,56,48,40,32,24,16, 8,
X 57,49,41,33,25,17, 9, 1,59,51,43,35,27,19,11, 3,
X 61,53,45,37,29,21,13, 5,63,55,47,39,31,23,15, 7,
X};
X
Xstatic struct ordering FinalTr = {
X 40, 8,48,16,56,24,64,32,39, 7,47,15,55,23,63,31,
X 38, 6,46,14,54,22,62,30,37, 5,45,13,53,21,61,29,
X 36, 4,44,12,52,20,60,28,35, 3,43,11,51,19,59,27,
X 34, 2,42,10,50,18,58,26,33, 1,41, 9,49,17,57,25,
X};
X
Xstatic struct ordering swap = {
X 33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,
X 49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,
X 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,
X 17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,
X};
X
Xstatic struct ordering KeyTr1 = {
X 57,49,41,33,25,17, 9, 1,58,50,42,34,26,18,
X 10, 2,59,51,43,35,27,19,11, 3,60,52,44,36,
X 63,55,47,39,31,23,15, 7,62,54,46,38,30,22,
X 14, 6,61,53,45,37,29,21,13, 5,28,20,12, 4,
X};
X
Xstatic struct ordering KeyTr2 = {
X 14,17,11,24, 1, 5, 3,28,15, 6,21,10,
X 23,19,12, 4,26, 8,16, 7,27,20,13, 2,
X 41,52,31,37,47,55,30,40,51,45,33,48,
X 44,49,39,56,34,53,46,42,50,36,29,32,
X};
X
Xstatic struct ordering etr = {
X 32, 1, 2, 3, 4, 5, 4, 5, 6, 7, 8, 9,
X 8, 9,10,11,12,13,12,13,14,15,16,17,
X 16,17,18,19,20,21,20,21,22,23,24,25,
X 24,25,26,27,28,29,28,29,30,31,32, 1,
X};
X
Xstatic struct ordering ptr = {
X 16, 7,20,21,29,12,28,17, 1,15,23,26, 5,18,31,10,
X 2, 8,24,14,32,27, 3, 9,19,13,30, 6,22,11, 4,25,
X};
X
Xstatic unsigned char s_boxes[8][64] = {
X{ 14, 4,13, 1, 2,15,11, 8, 3,10, 6,12, 5, 9, 0, 7,
X 0,15, 7, 4,14, 2,13, 1,10, 6,12,11, 9, 5, 3, 8,
X 4, 1,14, 8,13, 6, 2,11,15,12, 9, 7, 3,10, 5, 0,
X 15,12, 8, 2, 4, 9, 1, 7, 5,11, 3,14,10, 0, 6,13,
X},
X
X{ 15, 1, 8,14, 6,11, 3, 4, 9, 7, 2,13,12, 0, 5,10,
X 3,13, 4, 7,15, 2, 8,14,12, 0, 1,10, 6, 9,11, 5,
X 0,14, 7,11,10, 4,13, 1, 5, 8,12, 6, 9, 3, 2,15,
X 13, 8,10, 1, 3,15, 4, 2,11, 6, 7,12, 0, 5,14, 9,
X},
X
X{ 10, 0, 9,14, 6, 3,15, 5, 1,13,12, 7,11, 4, 2, 8,
X 13, 7, 0, 9, 3, 4, 6,10, 2, 8, 5,14,12,11,15, 1,
X 13, 6, 4, 9, 8,15, 3, 0,11, 1, 2,12, 5,10,14, 7,
X 1,10,13, 0, 6, 9, 8, 7, 4,15,14, 3,11, 5, 2,12,
X},
X
X{ 7,13,14, 3, 0, 6, 9,10, 1, 2, 8, 5,11,12, 4,15,
X 13, 8,11, 5, 6,15, 0, 3, 4, 7, 2,12, 1,10,14, 9,
X 10, 6, 9, 0,12,11, 7,13,15, 1, 3,14, 5, 2, 8, 4,
X 3,15, 0, 6,10, 1,13, 8, 9, 4, 5,11,12, 7, 2,14,
X},
X
X{ 2,12, 4, 1, 7,10,11, 6, 8, 5, 3,15,13, 0,14, 9,
X 14,11, 2,12, 4, 7,13, 1, 5, 0,15,10, 3, 9, 8, 6,
X 4, 2, 1,11,10,13, 7, 8,15, 9,12, 5, 6, 3, 0,14,
X 11, 8,12, 7, 1,14, 2,13, 6,15, 0, 9,10, 4, 5, 3,
X},
X
X{ 12, 1,10,15, 9, 2, 6, 8, 0,13, 3, 4,14, 7, 5,11,
X 10,15, 4, 2, 7,12, 9, 5, 6, 1,13,14, 0,11, 3, 8,
X 9,14,15, 5, 2, 8,12, 3, 7, 0, 4,10, 1,13,11, 6,
X 4, 3, 2,12, 9, 5,15,10,11,14, 1, 7, 6, 0, 8,13,
X},
X
X{ 4,11, 2,14,15, 0, 8,13, 3,12, 9, 7, 5,10, 6, 1,
X 13, 0,11, 7, 4, 9, 1,10,14, 3, 5,12, 2,15, 8, 6,
X 1, 4,11,13,12, 3, 7,14,10,15, 6, 8, 0, 5, 9, 2,
X 6,11,13, 8, 1, 4,10, 7, 9, 5, 0,15,14, 2, 3,12,
X},
X
X{ 13, 2, 8, 4, 6,15,11, 1,10, 9, 3,14, 5, 0,12, 7,
X 1,15,13, 8,10, 3, 7, 4,12, 5, 6,11, 0,14, 9, 2,
X 7,11, 4, 1, 9,12,14, 2, 0, 6,10,13,15, 3, 5, 8,
X 2, 1,14, 7, 4,10, 8,13,15,12, 9, 0, 3, 5, 6,11,
X},
X};
X
Xstatic int rots[] = {
X 1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1,
X};
X
Xstatic
Xtranspose(data, t, n)
X register struct block *data;
X register struct ordering *t;
X register int n;
X{
X struct block x;
X
X x = *data;
X
X while (n-- > 0) {
X data->b_data[n] = x.b_data[t->o_data[n] - 1];
X }
X}
X
Xstatic
Xrotate(key)
X register struct block *key;
X{
X register unsigned char *p = key->b_data;
X register unsigned char *ep = &(key->b_data[55]);
X int data0 = key->b_data[0], data28 = key->b_data[28];
X
X while (p++ < ep) *(p-1) = *p;
X key->b_data[27] = data0;
X key->b_data[55] = data28;
X}
X
Xstatic struct ordering *EP = &etr;
X
Xstatic
Xf(i, key, a, x)
X struct block *key, *a;
X register struct block *x;
X{
X struct block e, ikey, y;
X int k;
X register unsigned char *p, *q, *r;
X
X e = *a;
X transpose(&e, EP, 48);
X for (k = rots[i]; k; k--) rotate(key);
X ikey = *key;
X transpose(&ikey, &KeyTr2, 48);
X p = &(y.b_data[48]);
X q = &(e.b_data[48]);
X r = &(ikey.b_data[48]);
X while (p > y.b_data) {
X *--p = *--q ^ *--r;
X }
X q = x->b_data;
X for (k = 0; k < 8; k++) {
X register int xb, r;
X
X r = *p++ << 5;
X r += *p++ << 3;
X r += *p++ << 2;
X r += *p++ << 1;
X r += *p++;
X r += *p++ << 4;
X
X xb = s_boxes[k][r];
X
X *q++ = (xb >> 3) & 1;
X *q++ = (xb>>2) & 1;
X *q++ = (xb>>1) & 1;
X *q++ = (xb & 1);
X }
X transpose(x, &ptr, 32);
X}
X
Xsetkey(k)
X register char *k;
X{
X
X key = *((struct block *) k);
X transpose(&key, &KeyTr1, 56);
X}
X
Xencrypt(blck, edflag)
X char *blck;
X{
X register struct block *p = (struct block *) blck;
X register int i;
X
X transpose(p, &InitialTr, 64);
X for (i = 15; i>= 0; i--) {
X int j = edflag ? i : 15 - i;
X register int k;
X struct block b, x;
X
X b = *p;
X for (k = 31; k >= 0; k--) {
X p->b_data[k] = b.b_data[k + 32];
X }
X f(j, &key, p, &x);
X for (k = 31; k >= 0; k--) {
X p->b_data[k+32] = b.b_data[k] ^ x.b_data[k];
X }
X }
X transpose(p, &swap, 64);
X transpose(p, &FinalTr, 64);
X}
X
Xchar *
Xcrypt(pw,salt)
X register char *pw;
X char *salt;
X{
X /* Unfortunately, I had to look at the sources of V7 crypt.
X There was no other way to find out what this routine
X actually does.
X */
X
X char pwb[66];
X static char result[16];
X register char *p = pwb;
X struct ordering new_etr;
X register int i;
X
X while (*pw && p < &pwb[64]) {
X register int j = 7;
X
X while (j--) {
X *p++ = (*pw >> j) & 01;
X }
X pw++;
X *p++ = 0;
X }
X while (p < &pwb[64]) *p++ = 0;
X
X setkey(p = pwb);
X
X while (p < &pwb[66]) *p++ = 0;
X
X new_etr = etr;
X EP = &new_etr;
X for (i = 0; i < 2; i++) {
X register char c = *salt++;
X register int j;
X
X result[i] = c;
X if ( c > 'Z') c -= 6 + 7 + '.'; /* c was a lower case letter */
X else if ( c > '9') c -= 7 + '.';/* c was upper case letter */
X else c -= '.'; /* c was digit, '.' or '/'. */
X /* now, 0 <= c <= 63 */
X for (j = 0; j < 6; j++) {
X if ((c >> j) & 01) {
X int t = 6*i + j;
X int temp = new_etr.o_data[t];
X new_etr.o_data[t] = new_etr.o_data[t+24];
X new_etr.o_data[t+24] = temp;
X }
X }
X }
X
X if (result[1] == 0) result[1] = result[0];
X
X for (i = 0; i < 25; i++) encrypt(pwb,0);
X EP = &etr;
X
X p = pwb;
X pw = result+2;
X while (p < &pwb[66]) {
X register int c = 0;
X register int j = 6;
X
X while (j--) {
X c <<= 1;
X c |= *p++;
X }
X c += '.'; /* becomes >= '.' */
X if (c > '9') c += 7; /* not in [./0-9], becomes upper */
X if (c > 'Z') c += 6; /* not in [A-Z], becomes lower */
X *pw++ = c;
X }
X *pw = 0;
X return result;
X}
+ END-OF-FILE crypt.c
chmod 'u=rw,g=r,o=r' \c\r\y\p\t\.\c
set `sum \c\r\y\p\t\.\c`
sum=$1
case $sum in
07161) :;;
*) echo 'Bad sum in '\c\r\y\p\t\.\c >&2
esac
echo Extracting \f\s\:\l\i\n\k\.\c
sed 's/^X//' > \f\s\:\l\i\n\k\.\c << '+ END-OF-FILE '\f\s\:\l\i\n\k\.\c
X55c55,58
X< if (fetch_name(name2, name2_length, M1) != OK) return(err_code);
X---
X> if (fetch_name(name2, name2_length, M1) != OK) {
X> put_inode(rip);
X> return(err_code);
X> }
+ END-OF-FILE fs:link.c
chmod 'u=rw,g=r,o=r' \f\s\:\l\i\n\k\.\c
set `sum \f\s\:\l\i\n\k\.\c`
sum=$1
case $sum in
01679) :;;
*) echo 'Bad sum in '\f\s\:\l\i\n\k\.\c >&2
esac
echo Extracting \f\s\:\m\i\s\c\.\c
sed 's/^X//' > \f\s\:\m\i\s\c\.\c << '+ END-OF-FILE '\f\s\:\m\i\s\c\.\c
X169a170,176
X> if (fp->fp_suspended == SUSPENDED) {
X> if (fp->fp_task == XPIPE) susp_count--;
X> pro = exitee;
X> do_unpause();
X> fp->fp_suspended = NOT_SUSPENDED;
X> }
X>
X180,185d186
X< if (fp->fp_suspended == SUSPENDED) {
X< if (fp->fp_task == XPIPE) susp_count--;
X< pro = exitee;
X< do_unpause();
X< fp->fp_suspended = NOT_SUSPENDED;
X< }
+ END-OF-FILE fs:misc.c
chmod 'u=rw,g=r,o=r' \f\s\:\m\i\s\c\.\c
set `sum \f\s\:\m\i\s\c\.\c`
sum=$1
case $sum in
05012) :;;
*) echo 'Bad sum in '\f\s\:\m\i\s\c\.\c >&2
esac
echo Extracting \f\s\:\p\i\p\e\.\c
sed 's/^X//' > \f\s\:\p\i\p\e\.\c << '+ END-OF-FILE '\f\s\:\p\i\p\e\.\c
X201c201
X< if (rfp->fp_suspended == NOT_SUSPENDED) return;
X---
X> if (rfp->fp_suspended == NOT_SUSPENDED || rfp->fp_revived == REVIVING)return;
X231c231
X< int proc_nr, task;
X---
X> int proc_nr, task, fild;
X244c244,246
X< f = get_filp(rfp->fp_fd);
X---
X> fild = (rfp->fp_fd >> 8) & BYTE; /* extract file descriptor */
X> if (fild < 0 || fild >= NR_FDS) panic("unpause err 2", NO_NUM);
X> f = rfp->fp_filp[fild];
X249,252c251,254
X< if (sendrec(task, &mess) != OK) panic("unpause err 2", NO_NUM);
X< while (mess.REP_PROC_NR != proc_nr) {
X< revive(mess.REP_PROC_NR, mess.REP_STATUS);
X< if (receive(task, &m) != OK) panic("unpause err 3", NO_NUM);
X---
X> if (sendrec(task, &mess) != OK) panic("unpause err 3", NO_NUM);
X> while (mess.REP_PROC_NR != proc_nr) {
X> revive(mess.REP_PROC_NR, mess.REP_STATUS);
X> if (receive(task, &m) != OK) panic("unpause err 4", NO_NUM);
+ END-OF-FILE fs:pipe.c
chmod 'u=rw,g=r,o=r' \f\s\:\p\i\p\e\.\c
set `sum \f\s\:\p\i\p\e\.\c`
sum=$1
case $sum in
32696) :;;
*) echo 'Bad sum in '\f\s\:\p\i\p\e\.\c >&2
esac
echo Extracting \f\s\:\p\r\o\t\e\c\t\.\c
sed 's/^X//' > \f\s\:\p\r\o\t\e\c\t\.\c << '+ END-OF-FILE '\f\s\:\p\r\o\t\e\c\t\.\c
X151c151
X< if (super_user) {
X---
X> if (test_uid == SU_UID) {
+ END-OF-FILE fs:protect.c
chmod 'u=rw,g=r,o=r' \f\s\:\p\r\o\t\e\c\t\.\c
set `sum \f\s\:\p\r\o\t\e\c\t\.\c`
sum=$1
case $sum in
07444) :;;
*) echo 'Bad sum in '\f\s\:\p\r\o\t\e\c\t\.\c >&2
esac
echo Extracting \i\n\c\l\u\d\e\:\c\t\y\p\e\.
sed 's/^X//' > \i\n\c\l\u\d\e\:\c\t\y\p\e\. << '+ END-OF-FILE '\i\n\c\l\u\d\e\:\c\t\y\p\e\.
X21a22,24
X>
X> #define toupper(c) ((c) - 'a' + 'A')
X> #define tolower(c) ((c) - 'A' + 'a')
+ END-OF-FILE include:ctype.
chmod 'u=rw,g=r,o=r' \i\n\c\l\u\d\e\:\c\t\y\p\e\.
set `sum \i\n\c\l\u\d\e\:\c\t\y\p\e\.`
sum=$1
case $sum in
53050) :;;
*) echo 'Bad sum in '\i\n\c\l\u\d\e\:\c\t\y\p\e\. >&2
esac
echo Extracting \i\n\c\l\u\d\e\:\s\t\d\i\o\.
sed 's/^X//' > \i\n\c\l\u\d\e\:\s\t\d\i\o\. << '+ END-OF-FILE '\i\n\c\l\u\d\e\:\s\t\d\i\o\.
X38d37
X< #define puts(s) fputs(s,stdout)
+ END-OF-FILE include:stdio.
chmod 'u=rw,g=r,o=r' \i\n\c\l\u\d\e\:\s\t\d\i\o\.
set `sum \i\n\c\l\u\d\e\:\s\t\d\i\o\.`
sum=$1
case $sum in
33279) :;;
*) echo 'Bad sum in '\i\n\c\l\u\d\e\:\s\t\d\i\o\. >&2
esac
echo Extracting \k\e\r\n\e\l\:\f\l\o\p\p\y\.
sed 's/^X//' > \k\e\r\n\e\l\:\f\l\o\p\p\y\. << '+ END-OF-FILE '\k\e\r\n\e\l\:\f\l\o\p\p\y\.
X108c108
X< #define NT 4 /* number of diskette/drive combinations */
X---
X> #define NT 6 /* number of diskette/drive combinations */
X141,153c141,161
X< /* Four combinations of diskette/drive are supported:
X< * # Drive diskette Sectors Tracks Rotation Data-rate Comment
X< * 0 360K 360K 9 40 300 RPM 250 kbps Standard PC DSDD
X< * 1 720K 360K 9 40 300 RPM 250 kbps Quad density PC
X< * 2 1.2M 360K 9 40 360 RPM 300 kbps PC disk in AT drive
X< * 3 1.2M 1.2M 15 80 360 RPM 500 kbps AT disk in AT drive
X< */
X< PRIVATE int gap[NT] = {0x2A, 0x2A, 0x23, 0x1B}; /* gap size */
X< PRIVATE int rate[NT] = {0x02, 0x02, 0x01, 0x00}; /* 250,300,500 kbps*/
X< PRIVATE int nr_sectors[NT] = {9, 9, 9, 15}; /* sectors/track */
X< PRIVATE int nr_blocks[NT] = {720, 720, 720, 2400}; /* sectors/diskette*/
X< PRIVATE int steps_per_cyl[NT] = {1, 2, 2, 1}; /* 2 = dbl step */
X< PRIVATE int mtr_setup[NT] = {HZ/4,HZ/4,3*HZ/4,3*HZ/4};/* in ticks */
X---
X> /* Six combinations of diskette/drive are supported:
X> * # Drive diskette Sectors Tracks Rotation Data-rate Comment
X> * 0 360K 360K 9 40 300 RPM 250 kbps Standard PC DSDD
X> * 1 1.2M 1.2M 15 80 360 RPM 500 kbps AT disk in AT drive
X> * 2 720K 360K 9 40 300 RPM 250 kbps Quad density PC
X> * 3 720K 720K 9 80 300 RPM 250 kbps Toshiba, et al.
X> * 4 1.2M 360K 9 40 360 RPM 300 kbps PC disk in AT drive
X> * 5 1.2M 720K 9 80 360 RPM 300 kbps Toshiba in AT drive
X> */
X> PRIVATE int gap[NT] =
X> {0x2A, 0x1B, 0x2A, 0x2A, 0x23, 0x23}; /* gap size */
X> PRIVATE int rate[NT] =
X> {0x02, 0x00, 0x02, 0x02, 0x01, 0x01}; /* 250,300,500 kbps*/
X> PRIVATE int nr_sectors[NT] =
X> {9, 15, 9, 9, 9, 9}; /* sectors/track */
X> PRIVATE int nr_blocks[NT] =
X> {720, 2400, 720, 1440, 720, 1440}; /* sectors/diskette*/
X> PRIVATE int steps_per_cyl[NT] =
X> {1, 1, 2, 1, 2, 1}; /* 2 = dbl step */
X> PRIVATE int mtr_setup[NT] =
X> {HZ/4,3*HZ/4,HZ/4,HZ/4,3*HZ/4,3*HZ/4};/* in ticks */
+ END-OF-FILE kernel:floppy.
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\f\l\o\p\p\y\.
set `sum \k\e\r\n\e\l\:\f\l\o\p\p\y\.`
sum=$1
case $sum in
25397) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\f\l\o\p\p\y\. >&2
esac
echo Extracting \k\e\r\n\e\l\:\k\l\i\b\8\8\.
sed 's/^X//' > \k\e\r\n\e\l\:\k\l\i\b\8\8\. << '+ END-OF-FILE '\k\e\r\n\e\l\:\k\l\i\b\8\8\.
X18a19,20
X> | dma_read: transfer data between HD controller and memory
X> | dma_write: transfer data between memory and HD controller
X23c25
X< .globl _wreboot, _portw_in, _portw_out
X---
X> .globl _wreboot, _dma_read, _dma_write
X215,229c217,223
X< |* portw_out *
X< |*===========================================================================*
X< | portw_out(port, value) writes 'value' on the I/O port 'port'.
X<
X< _portw_out:
X< push bx | save bx
X< mov bx,sp | index off bx
X< push ax | save ax
X< push dx | save dx
X< mov dx,4(bx) | dx = port
X< mov ax,6(bx) | ax = value
X< outw | output 1 word
X< pop dx | restore dx
X< pop ax | restore ax
X< pop bx | restore bx
X---
X> |* lock *
X> |*===========================================================================*
X> | Disable CPU interrupts.
X> _lock:
X> pushf | save flags on stack
X> cli | disable interrupts
X> pop lockvar | save flags for possible restoration later
X234,258c228,232
X< |* portw_in *
X< |*===========================================================================*
X< | portw_in(port, &value) reads from port 'port' and puts the result in 'value'.
X< _portw_in:
X< push bx | save bx
X< mov bx,sp | index off bx
X< push ax | save ax
X< push dx | save dx
X< mov dx,4(bx) | dx = port
X< inw | input 1 word
X< mov bx,6(bx) | fetch address where byte is to go
X< mov (bx),ax | return byte to caller in param
X< pop dx | restore dx
X< pop ax | restore ax
X< pop bx | restore bx
X< ret | return to caller
X<
X< |*===========================================================================*
X< |* lock *
X< |*===========================================================================*
X< | Disable CPU interrupts.
X< _lock:
X< pushf | save flags on stack
X< cli | disable interrupts
X< pop lockvar | save flags for possible restoration later
X---
X> |* unlock *
X> |*===========================================================================*
X> | Enable CPU interrupts.
X> _unlock:
X> sti | enable interrupts
X263,267c237,242
X< |* unlock *
X< |*===========================================================================*
X< | Enable CPU interrupts.
X< _unlock:
X< sti | enable interrupts
X---
X> |* restore *
X> |*===========================================================================*
X> | Restore enable/disable bit to the value it had before last lock.
X> _restore:
X> push lockvar | push flags as they were before previous lock
X> popf | restore flags
X272,281d246
X< |* restore *
X< |*===========================================================================*
X< | Restore enable/disable bit to the value it had before last lock.
X< _restore:
X< push lockvar | push flags as they were before previous lock
X< popf | restore flags
X< ret | return to caller
X<
X<
X< |*===========================================================================*
X370a336,382
X> |*===========================================================================*
X> |* dma_read *
X> |*===========================================================================*
X> _dma_read:
X> push bp
X> mov bp,sp
X> push cx
X> push dx
X> push di
X> push es
X> mov cx,#256 | transfer 256 words
X> mov dx,#0x1F0 | from/to port 1f0
X> cld
X> mov es,4(bp) | segment in es
X> mov di,6(bp) | offset in di
X> .byte 0xF3, 0x6D | opcode for 'rep insw'
X> pop es
X> pop di
X> pop dx
X> pop dx
X> mov sp,bp
X> pop bp
X> ret
X>
X> |*===========================================================================*
X> |* dma_write *
X> |*===========================================================================*
X> _dma_write:
X> push bp
X> mov bp,sp
X> push cx
X> push dx
X> push si
X> push ds
X> mov cx,#256 | transfer 256 words
X> mov dx,#0x1F0 | from/to port 1f0
X> cld
X> mov ds,4(bp) | segment in ds
X> mov si,6(bp) | offset in si
X> .byte 0xF3, 0x6F | opcode for 'rep outsw'
X> pop ds
X> pop si
X> pop dx
X> pop dx
X> mov sp,bp
X> pop bp
X> ret
X431c443
X< nop | 'lock' indicates a video ram access
X---
X> inc vidlock | 'lock' indicates a video ram access
X496c508,518
X< int 0x19 | reboot the PC
X---
X> mov ax,#0x40
X> mov ds,ax
X> mov ax,#0x1234
X> mov 0x72,ax
X> mov ax,#0xFFFF
X> mov ds,ax
X> mov ax,3
X> push ax
X> mov ax,1
X> push ax
X> reti
X505c527,537
X< int 0x19 | reboot the PC
X---
X> mov ax,#0x40
X> mov ds,ax
X> mov ax,#0x1234
X> mov 0x72,ax
X> mov ax,#0xFFFF
X> mov ds,ax
X> mov ax,3
X> push ax
X> mov ax,1
X> push ax
X> reti
X524a557
X> vidlock: .word 0 | dummy variable for use with lock prefix
+ END-OF-FILE kernel:klib88.
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\k\l\i\b\8\8\.
set `sum \k\e\r\n\e\l\:\k\l\i\b\8\8\.`
sum=$1
case $sum in
22765) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\k\l\i\b\8\8\. >&2
esac
echo Extracting \k\e\r\n\e\l\:\m\a\k\e\f\i\l
sed 's/^X//' > \k\e\r\n\e\l\:\m\a\k\e\f\i\l << '+ END-OF-FILE '\k\e\r\n\e\l\:\m\a\k\e\f\i\l
X1,3c1,7
X< # The kernel directory contains files xt_wini.c and at_wini.c. Before running
X< # make you must copy one of these to wini.c, depending on whether you have a
X< # PC or an AT. You must do this even if you do not have a hard disk..
X---
X> # The kernel dir contains wd_wini.c, xt_wini.c and at_wini.c. Before running
X> # make you must copy one of these to wini.c, depending on which controller you
X> # have. If you do not have a hard disk, you MUST choose one of them at random.
X> # On a PC, cpp and cem are in /lib and will be removed to make space while
X> # linking the kernel. On an AT, they are in /usr/lib are are not removed.
X> # This is because they have to be in /lib on a PC; the diskette is too small
X> # for them to be in /usr/lib.
X8c12
X< obj = mpx88.s main.s proc.s system.s tty.s clock.s memory.s floppy.s wini.s \
X---
X> obj = mpx88.s main.s tty.s floppy.s wini.s system.s proc.s clock.s memory.s \
X12,15c16,21
X< @echo "Start linking Kernel. /lib/cem will be removed to make space on RAM disk"
X< @rm -f /lib/cem /tmp/*
X< @asld -o kernel $(obj) $l/libc.a $l/end.s
X< @echo "Kernel done. Please restore /lib/cem manually"
X---
X> @echo "Start linking Kernel."
X> @echo "On a PC, /lib/* will be removed to make space on RAM disk"
X> @echo "If linking fails due to lack of space on 2/1, rm xx_wini.c"
X> @rm -f /lib/cem /lib/cpp /tmp/*
X> @asld -o kernel $(obj) $l/libc.a $l/end.s
X> @echo "Kernel done. On a PC, restore /lib/cem and /lib/cpp manually"
+ END-OF-FILE kernel:makefil
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\m\a\k\e\f\i\l
set `sum \k\e\r\n\e\l\:\m\a\k\e\f\i\l`
sum=$1
case $sum in
36557) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\m\a\k\e\f\i\l >&2
esac
echo Extracting \k\e\r\n\e\l\:\p\r\i\n\t\e\r
sed 's/^X//' > \k\e\r\n\e\l\:\p\r\i\n\t\e\r << '+ END-OF-FILE '\k\e\r\n\e\l\:\p\r\i\n\t\e\r
X33,34c33,34
X< #define NORMAL_STATUS 0xDF /* printer gives this status when idle */
X< #define BUSY_STATUS 0x5F /* printer gives this status when busy */
X---
X> #define NORMAL_STATUS 0x90 /* printer gives this status when idle */
X> #define BUSY_STATUS 0x10 /* printer gives this status when busy */
X48a49
X> #define STATUS_MASK 0xB0 /* mask to filter out status bits */
X121c122
X< if (value == NORMAL_STATUS) {
X---
X> if ((value&STATUS_MASK) == NORMAL_STATUS) {
X127c128
X< if (value == BUSY_STATUS) {
X---
X> if ((value&STATUS_MASK) == BUSY_STATUS) {
X139c140
X< if (value == BUSY_STATUS) r = EAGAIN;
X---
X> if ((value&STATUS_MASK) == BUSY_STATUS) r = EAGAIN;
X253c254
X< if (value == NORMAL_STATUS) {
X---
X> if ((value&STATUS_MASK) == NORMAL_STATUS) {
X264c265
X< } else if (value == BUSY_STATUS) {
X---
X> } else if ((value&STATUS_MASK) == BUSY_STATUS) {
X275a277,278
X>
X>
+ END-OF-FILE kernel:printer
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\p\r\i\n\t\e\r
set `sum \k\e\r\n\e\l\:\p\r\i\n\t\e\r`
sum=$1
case $sum in
44270) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\p\r\i\n\t\e\r >&2
esac
echo Extracting \k\e\r\n\e\l\:\p\r\o\c\.\c
sed 's/^X//' > \k\e\r\n\e\l\:\p\r\o\c\.\c << '+ END-OF-FILE '\k\e\r\n\e\l\:\p\r\o\c\.\c
X40c40,42
X< if (pc_at) port_out(INT2_CTL, ENABLE); /* re-enable second 8259A */
X---
X> if (pc_at && task == WINCHESTER)
X> /* this re-enables the second controller chip */
X> port_out(INT2_CTL, ENABLE);
+ END-OF-FILE kernel:proc.c
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\p\r\o\c\.\c
set `sum \k\e\r\n\e\l\:\p\r\o\c\.\c`
sum=$1
case $sum in
20827) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\p\r\o\c\.\c >&2
esac
echo Extracting \k\e\r\n\e\l\:\t\t\y\.\c
sed 's/^X//' > \k\e\r\n\e\l\:\t\t\y\.\c << '+ END-OF-FILE '\k\e\r\n\e\l\:\t\t\y\.\c
X79c79,80
X< #define F10 68 /* scan code for function key F9 */
X---
X> #define F9 67 /* scan code for function key F9 */
X> #define F10 68 /* scan code for function key F10 */
X151a153,154
X> PRIVATE caps_off = 1; /* 1 = normal position, 0 = depressed */
X> PRIVATE num_off = 1; /* 1 = normal position, 0 = depressed */
X154a158
X>
X162c166
X< ,0261, 0262,0263,'0',0177
X---
X> ,0261,0262,0263,'0',0177
X172c176
X< '2','3','0',177
X---
X> '2','3','0','.'
X312,315c316,320
X< chuck(tp); /* remove last char entered */
X< echo(tp, '\b'); /* remove it from the screen */
X< echo(tp, ' ');
X< echo(tp, '\b');
X---
X> if (chuck(tp) != -1) { /* remove last char entered */
X> echo(tp, '\b'); /* remove it from the screen */
X> echo(tp, ' ');
X> echo(tp, '\b');
X> }
X362,368c367
X< tp->tty_inhibited = RUNNING; /* do implied CRTL-Q */
X< finish(tp, EINTR); /* send reply */
X< tp->tty_inhead = tp->tty_inqueue; /* discard input */
X< tp->tty_intail = tp->tty_inqueue;
X< tp->tty_incount = 0;
X< tp->tty_lfct = 0;
X< cause_sig(LOW_USER + 1 + line, sig);
X---
X> sigchar(tp, line, sig);
X415,422c414,423
X< code = (shift1 || shift2 || capslock ? sh[c] : unsh[c]);
X< if (control && c < TOP_ROW) code = sh[c]; /* CTRL-(top row) */
X< if (c > 70 && numlock) code = sh[c]; /* numlock depressed */
X< } else {
X< /* (Olivetti M24 or AT&T 6300) with Olivetti-style keyboard. */
X< code = (shift1 || shift2 || capslock ? m24[c] : unm24[c]);
X< if (control && c < TOP_ROW) code = sh[c]; /* CTRL-(top row) */
X< if (c > 70 && numlock) code = m24[c]; /* numlock depressed */
X---
X> code = (shift1 || shift2 ? sh[c] : unsh[c]);
X> if (control && c < TOP_ROW) code = sh[c]; /* CTRL-(top row) */
X> if (c > 70 && numlock) /* numlock depressed */
X> code = (shift1 || shift2 ? unsh[c] : sh[c]);
X> } else {
X> /* (Olivetti M24 or AT&T 6300) with Olivetti-style keyboard. */
X> code = (shift1 || shift2 ? m24[c] : unm24[c]);
X> if (control && c < TOP_ROW) code = sh[c]; /* CTRL-(top row) */
X> if (c > 70 && numlock) /* numlock depressed */
X> code = (shift1 || shift2 ? unm24[c] : m24[c]);
X426a428,432
X> if (capslock)
X> if (code >= 'A' && code <= 'Z')
X> code += 'a' - 'A';
X> else if (code >= 'a' && code <= 'z')
X> code -= 'a' - 'A';
X440,441c446,451
X< case 4: if (make) capslock = 1 - capslock; break; /* caps lock */
X< case 5: if (make) numlock = 1 - numlock; break; /* num lock */
X---
X> case 4: if (make && caps_off) capslock = 1 - capslock;
X> caps_off = 1 - make;
X> break; /* caps lock */
X> case 5: if (make && num_off) numlock = 1 - numlock;
X> num_off = 1 - make;
X> break; /* num lock */
X755a766,785
X> /*===========================================================================*
X> * sigchar *
X> *===========================================================================*/
X> PRIVATE sigchar(tp, line, sig)
X> register struct tty_struct *tp; /* pointer to tty_struct */
X> int line; /* line on which signal arrived */
X> int sig; /* SIGINT, SIGQUIT, or SIGKILL */
X> {
X> /* Process a SIGINT, SIGQUIT or SIGKILL char from the keyboard */
X>
X> tp->tty_inhibited = RUNNING; /* do implied CRTL-Q */
X> finish(tp, EINTR); /* send reply */
X> tp->tty_inhead = tp->tty_inqueue; /* discard input */
X> tp->tty_intail = tp->tty_inqueue;
X> tp->tty_incount = 0;
X> tp->tty_lfct = 0;
X> cause_sig(LOW_USER + 1 + line, sig);
X> }
X>
X>
X792a823
X> #define EGA 0x3C0 /* port for EGA card */
X833c864
X< * The shift-type keys, 29, 42, 54, 56, and 69 must be processed normally.
X---
X> * The shift-type keys, 29, 42, 54, 56, 58, and 69 must be processed normally.
X838c869
X< if (k != 29 && k != 42 && k != 54 && k != 56 && k != 69) {
X---
X> if (k != 29 && k != 42 && k != 54 && k != 56 && k != 58 && k != 69) {
X1168a1200,1203
X> /* Tell the EGA card, if any, to simulate a 16K CGA card. */
X> port_out(EGA + INDEX, 4); /* register select */
X> port_out(EGA + DATA, 1); /* no extended memory to be used */
X>
X1237,1238c1272,1275
X< }
X< #endif
X---
X> if (ch == F9) sigchar(&tty_struct[0], 0, SIGKILL); /* issue SIGKILL */
X> }
X> #endif
X>
+ END-OF-FILE kernel:tty.c
chmod 'u=rw,g=r,o=r' \k\e\r\n\e\l\:\t\t\y\.\c
set `sum \k\e\r\n\e\l\:\t\t\y\.\c`
sum=$1
case $sum in
21674) :;;
*) echo 'Bad sum in '\k\e\r\n\e\l\:\t\t\y\.\c >&2
esac
exit 0
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!mcvax!botter!ast
From: a...@cs.vu.nl (Andy Tanenbaum)
Newsgroups: comp.os.minix
Subject: Definitive MINIX 1.2 updates (Part 4 of 4)
Message-ID: <1565@botter.cs.vu.nl>
Date: Sun, 9-Aug-87 17:57:37 EDT
Article-I.D.: botter.1565
Posted: Sun Aug 9 17:57:37 1987
Date-Received: Tue, 11-Aug-87 00:46:26 EDT
Reply-To: a...@cs.vu.nl (Andy Tanenbaum)
Distribution: world
Organization: VU Informatica, Amsterdam
Lines: 1131
: This is a shar archive. Extract with sh, not csh.
: This archive ends with exit, so do not worry about trailing junk.
: --------------------------- cut here --------------------------
PATH=/bin:/usr/bin
echo Extracting \l\i\b\:\c\r\y\p\t\.\c
sed 's/^X//' > \l\i\b\:\c\r\y\p\t\.\c << '+ END-OF-FILE '\l\i\b\:\c\r\y\p\t\.\c
X1,40c1,294
X< char *crypt(pw, salt)
X< char *pw, *salt;
X< {
X< static char buf[14];
X< register char bits[67];
X< register int i;
X< register int j, rot;
X<
X< for (i=0; i < 67; i++)
X< bits[i] = 0;
X< if (salt[1] == 0)
X< salt[1] = salt[0];
X< rot = (salt[1] * 4 - salt[0]) % 128;
X< for (i=0; *pw && i < 8; i++) {
X< for (j=0; j < 7; j++)
X< bits[i+j*8] = (*pw & (1 << j) ? 1 : 0);
X< bits[i+56] = (salt[i / 4] & (1 << (i % 4)) ? 1 : 0);
X< pw++;
X< }
X< bits[64] = (salt[0] & 1 ? 1 : 0);
X< bits[65] = (salt[1] & 1 ? 1 : 0);
X< bits[66] = (rot & 1 ? 1 : 0);
X< while (rot--) {
X< for (i=65; i >= 0; i--)
X< bits[i+1] = bits[i];
X< bits[0] = bits[66];
X< }
X< for (i=0; i < 12; i++) {
X< buf[i+2] = 0;
X< for (j=0; j < 6; j++)
X< buf[i+2] |= (bits[i*6+j] ? (1 << j) : 0);
X< buf[i+2] += 48;
X< if (buf[i+2] > '9') buf[i+2] += 7;
X< if (buf[i+2] > 'Z') buf[i+2] += 6;
X< }
X< buf[0] = salt[0];
X< buf[1] = salt[1];
X< buf[13] = '\0';
X< return(buf);
X< }
X---
X> /* From Andy Tanenbaum's book "Computer Networks",
X> rewritten in C
X> */
X>
X> struct block {
X> unsigned char b_data[64];
X> };
X>
X> struct ordering {
X> unsigned char o_data[64];
X> };
X>
X> static struct block key;
X>
X> static struct ordering InitialTr = {
X> 58,50,42,34,26,18,10, 2,60,52,44,36,28,20,12, 4,
X> 62,54,46,38,30,22,14, 6,64,56,48,40,32,24,16, 8,
X> 57,49,41,33,25,17, 9, 1,59,51,43,35,27,19,11, 3,
X> 61,53,45,37,29,21,13, 5,63,55,47,39,31,23,15, 7,
X> };
X>
X> static struct ordering FinalTr = {
X> 40, 8,48,16,56,24,64,32,39, 7,47,15,55,23,63,31,
X> 38, 6,46,14,54,22,62,30,37, 5,45,13,53,21,61,29,
X> 36, 4,44,12,52,20,60,28,35, 3,43,11,51,19,59,27,
X> 34, 2,42,10,50,18,58,26,33, 1,41, 9,49,17,57,25,
X> };
X>
X> static struct ordering swap = {
X> 33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,
X> 49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,
X> 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,
X> 17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,
X> };
X>
X> static struct ordering KeyTr1 = {
X> 57,49,41,33,25,17, 9, 1,58,50,42,34,26,18,
X> 10, 2,59,51,43,35,27,19,11, 3,60,52,44,36,
X> 63,55,47,39,31,23,15, 7,62,54,46,38,30,22,
X> 14, 6,61,53,45,37,29,21,13, 5,28,20,12, 4,
X> };
X>
X> static struct ordering KeyTr2 = {
X> 14,17,11,24, 1, 5, 3,28,15, 6,21,10,
X> 23,19,12, 4,26, 8,16, 7,27,20,13, 2,
X> 41,52,31,37,47,55,30,40,51,45,33,48,
X> 44,49,39,56,34,53,46,42,50,36,29,32,
X> };
X>
X> static struct ordering etr = {
X> 32, 1, 2, 3, 4, 5, 4, 5, 6, 7, 8, 9,
X> 8, 9,10,11,12,13,12,13,14,15,16,17,
X> 16,17,18,19,20,21,20,21,22,23,24,25,
X> 24,25,26,27,28,29,28,29,30,31,32, 1,
X> };
X>
X> static struct ordering ptr = {
X> 16, 7,20,21,29,12,28,17, 1,15,23,26, 5,18,31,10,
X> 2, 8,24,14,32,27, 3, 9,19,13,30, 6,22,11, 4,25,
X> };
X>
X> static unsigned char s_boxes[8][64] = {
X> { 14, 4,13, 1, 2,15,11, 8, 3,10, 6,12, 5, 9, 0, 7,
X> 0,15, 7, 4,14, 2,13, 1,10, 6,12,11, 9, 5, 3, 8,
X> 4, 1,14, 8,13, 6, 2,11,15,12, 9, 7, 3,10, 5, 0,
X> 15,12, 8, 2, 4, 9, 1, 7, 5,11, 3,14,10, 0, 6,13,
X> },
X>
X> { 15, 1, 8,14, 6,11, 3, 4, 9, 7, 2,13,12, 0, 5,10,
X> 3,13, 4, 7,15, 2, 8,14,12, 0, 1,10, 6, 9,11, 5,
X> 0,14, 7,11,10, 4,13, 1, 5, 8,12, 6, 9, 3, 2,15,
X> 13, 8,10, 1, 3,15, 4, 2,11, 6, 7,12, 0, 5,14, 9,
X> },
X>
X> { 10, 0, 9,14, 6, 3,15, 5, 1,13,12, 7,11, 4, 2, 8,
X> 13, 7, 0, 9, 3, 4, 6,10, 2, 8, 5,14,12,11,15, 1,
X> 13, 6, 4, 9, 8,15, 3, 0,11, 1, 2,12, 5,10,14, 7,
X> 1,10,13, 0, 6, 9, 8, 7, 4,15,14, 3,11, 5, 2,12,
X> },
X>
X> { 7,13,14, 3, 0, 6, 9,10, 1, 2, 8, 5,11,12, 4,15,
X> 13, 8,11, 5, 6,15, 0, 3, 4, 7, 2,12, 1,10,14, 9,
X> 10, 6, 9, 0,12,11, 7,13,15, 1, 3,14, 5, 2, 8, 4,
X> 3,15, 0, 6,10, 1,13, 8, 9, 4, 5,11,12, 7, 2,14,
X> },
X>
X> { 2,12, 4, 1, 7,10,11, 6, 8, 5, 3,15,13, 0,14, 9,
X> 14,11, 2,12, 4, 7,13, 1, 5, 0,15,10, 3, 9, 8, 6,
X> 4, 2, 1,11,10,13, 7, 8,15, 9,12, 5, 6, 3, 0,14,
X> 11, 8,12, 7, 1,14, 2,13, 6,15, 0, 9,10, 4, 5, 3,
X> },
X>
X> { 12, 1,10,15, 9, 2, 6, 8, 0,13, 3, 4,14, 7, 5,11,
X> 10,15, 4, 2, 7,12, 9, 5, 6, 1,13,14, 0,11, 3, 8,
X> 9,14,15, 5, 2, 8,12, 3, 7, 0, 4,10, 1,13,11, 6,
X> 4, 3, 2,12, 9, 5,15,10,11,14, 1, 7, 6, 0, 8,13,
X> },
X>
X> { 4,11, 2,14,15, 0, 8,13, 3,12, 9, 7, 5,10, 6, 1,
X> 13, 0,11, 7, 4, 9, 1,10,14, 3, 5,12, 2,15, 8, 6,
X> 1, 4,11,13,12, 3, 7,14,10,15, 6, 8, 0, 5, 9, 2,
X> 6,11,13, 8, 1, 4,10, 7, 9, 5, 0,15,14, 2, 3,12,
X> },
X>
X> { 13, 2, 8, 4, 6,15,11, 1,10, 9, 3,14, 5, 0,12, 7,
X> 1,15,13, 8,10, 3, 7, 4,12, 5, 6,11, 0,14, 9, 2,
X> 7,11, 4, 1, 9,12,14, 2, 0, 6,10,13,15, 3, 5, 8,
X> 2, 1,14, 7, 4,10, 8,13,15,12, 9, 0, 3, 5, 6,11,
X> },
X> };
X>
X> static int rots[] = {
X> 1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1,
X> };
X>
X> static
X> transpose(data, t, n)
X> register struct block *data;
X> register struct ordering *t;
X> register int n;
X> {
X> struct block x;
X>
X> x = *data;
X>
X> while (n-- > 0) {
X> data->b_data[n] = x.b_data[t->o_data[n] - 1];
X> }
X> }
X>
X> static
X> rotate(key)
X> register struct block *key;
X> {
X> register unsigned char *p = key->b_data;
X> register unsigned char *ep = &(key->b_data[55]);
X> int data0 = key->b_data[0], data28 = key->b_data[28];
X>
X> while (p++ < ep) *(p-1) = *p;
X> key->b_data[27] = data0;
X> key->b_data[55] = data28;
X> }
X>
X> static struct ordering *EP = &etr;
X>
X> static
X> f(i, key, a, x)
X> struct block *key, *a;
X> register struct block *x;
X> {
X> struct block e, ikey, y;
X> int k;
X> register unsigned char *p, *q, *r;
X>
X> e = *a;
X> transpose(&e, EP, 48);
X> for (k = rots[i]; k; k--) rotate(key);
X> ikey = *key;
X> transpose(&ikey, &KeyTr2, 48);
X> p = &(y.b_data[48]);
X> q = &(e.b_data[48]);
X> r = &(ikey.b_data[48]);
X> while (p > y.b_data) {
X> *--p = *--q ^ *--r;
X> }
X> q = x->b_data;
X> for (k = 0; k < 8; k++) {
X> register int xb, r;
X>
X> r = *p++ << 5;
X> r += *p++ << 3;
X> r += *p++ << 2;
X> r += *p++ << 1;
X> r += *p++;
X> r += *p++ << 4;
X>
X> xb = s_boxes[k][r];
X>
X> *q++ = (xb >> 3) & 1;
X> *q++ = (xb>>2) & 1;
X> *q++ = (xb>>1) & 1;
X> *q++ = (xb & 1);
X> }
X> transpose(x, &ptr, 32);
X> }
X>
X> setkey(k)
X> register char *k;
X> {
X>
X> key = *((struct block *) k);
X> transpose(&key, &KeyTr1, 56);
X> }
X>
X> encrypt(blck, edflag)
X> char *blck;
X> {
X> register struct block *p = (struct block *) blck;
X> register int i;
X>
X> transpose(p, &InitialTr, 64);
X> for (i = 15; i>= 0; i--) {
X> int j = edflag ? i : 15 - i;
X> register int k;
X> struct block b, x;
X>
X> b = *p;
X> for (k = 31; k >= 0; k--) {
X> p->b_data[k] = b.b_data[k + 32];
X> }
X> f(j, &key, p, &x);
X> for (k = 31; k >= 0; k--) {
X> p->b_data[k+32] = b.b_data[k] ^ x.b_data[k];
X> }
X> }
X> transpose(p, &swap, 64);
X> transpose(p, &FinalTr, 64);
X> }
X>
X> char *
X> crypt(pw,salt)
X> register char *pw;
X> char *salt;
X> {
X> /* Unfortunately, I had to look at the sources of V7 crypt.
X> There was no other way to find out what this routine
X> actually does.
X> */
X>
X> char pwb[66];
X> static char result[16];
X> register char *p = pwb;
X> struct ordering new_etr;
X> register int i;
X>
X> while (*pw && p < &pwb[64]) {
X> register int j = 7;
X>
X> while (j--) {
X> *p++ = (*pw >> j) & 01;
X> }
X> pw++;
X> *p++ = 0;
X> }
X> while (p < &pwb[64]) *p++ = 0;
X>
X> setkey(p = pwb);
X>
X> while (p < &pwb[66]) *p++ = 0;
X>
X> new_etr = etr;
X> EP = &new_etr;
X> for (i = 0; i < 2; i++) {
X> register char c = *salt++;
X> register int j;
X>
X> result[i] = c;
X> if ( c > 'Z') c -= 6 + 7 + '.'; /* c was a lower case letter */
X> else if ( c > '9') c -= 7 + '.';/* c was upper case letter */
X> else c -= '.'; /* c was digit, '.' or '/'. */
X> /* now, 0 <= c <= 63 */
X> for (j = 0; j < 6; j++) {
X> if ((c >> j) & 01) {
X> int t = 6*i + j;
X> int temp = new_etr.o_data[t];
X> new_etr.o_data[t] = new_etr.o_data[t+24];
X> new_etr.o_data[t+24] = temp;
X> }
X> }
X> }
X>
X> if (result[1] == 0) result[1] = result[0];
X>
X> for (i = 0; i < 25; i++) encrypt(pwb,0);
X> EP = &etr;
X>
X> p = pwb;
X> pw = result+2;
X> while (p < &pwb[66]) {
X> register int c = 0;
X> register int j = 6;
X>
X> while (j--) {
X> c <<= 1;
X> c |= *p++;
X> }
X> c += '.'; /* becomes >= '.' */
X> if (c > '9') c += 7; /* not in [./0-9], becomes upper */
X> if (c > 'Z') c += 6; /* not in [A-Z], becomes lower */
X> *pw++ = c;
X> }
X> *pw = 0;
X> return result;
X> }
+ END-OF-FILE lib:crypt.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\c\r\y\p\t\.\c
set `sum \l\i\b\:\c\r\y\p\t\.\c`
sum=$1
case $sum in
12716) :;;
*) echo 'Bad sum in '\l\i\b\:\c\r\y\p\t\.\c >&2
esac
echo Extracting \l\i\b\:\e\n\d\.\s
sed 's/^X//' > \l\i\b\:\e\n\d\.\s << '+ END-OF-FILE '\l\i\b\:\e\n\d\.\s
X1c1
X< .globl endtext, enddata, endbss
X---
X> .globl endtext, enddata, endbss, _end, _edata
X6,7c6,9
X< .bss
X< endbss:
X---
X> _edata:
X> .bss
X> endbss:
X> _end:
+ END-OF-FILE lib:end.s
chmod 'u=rw,g=r,o=r' \l\i\b\:\e\n\d\.\s
set `sum \l\i\b\:\e\n\d\.\s`
sum=$1
case $sum in
21833) :;;
*) echo 'Bad sum in '\l\i\b\:\e\n\d\.\s >&2
esac
echo Extracting \l\i\b\:\g\e\t\e\n\v\.\c
sed 's/^X//' > \l\i\b\:\g\e\t\e\n\v\.\c << '+ END-OF-FILE '\l\i\b\:\g\e\t\e\n\v\.\c
X1d0
X< #define NULL (char *) 0
X8,18c7,14
X< while ((p = *v) != NULL) {
X< q = name;
X< while (*p++ == *q)
X< if (*q++ == 0)
X< continue;
X< if (*(p - 1) != '=')
X< continue;
X< return(p);
X< }
X< return(0);
X< }
X---
X> while ((p = *v++) != 0) {
X> q = name;
X> while (*q && *q++ == *p++) /* nothing */ ;
X> if (*q || *p != '=') continue;
X> return(p+1);
X> }
X> return(0);
X> }
+ END-OF-FILE lib:getenv.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\g\e\t\e\n\v\.\c
set `sum \l\i\b\:\g\e\t\e\n\v\.\c`
sum=$1
case $sum in
06320) :;;
*) echo 'Bad sum in '\l\i\b\:\g\e\t\e\n\v\.\c >&2
esac
echo Extracting \l\i\b\:\g\e\t\p\w\e\n\t\.\c
sed 's/^X//' > \l\i\b\:\g\e\t\p\w\e\n\t\.\c << '+ END-OF-FILE '\l\i\b\:\g\e\t\p\w\e\n\t\.\c
X78,90c78,90
X< pwd.name = _buf;
X< skip_period ();
X< pwd.passwd = _buf;
X< skip_period ();
X< pwd.uid = atoi (_buf);
X< skip_period ();
X< pwd.gid = atoi (_buf);
X< skip_period ();
X< pwd.gecos = _buf;
X< skip_period ();
X< pwd.dir = _buf;
X< skip_period ();
X< pwd.shell = _buf;
X---
X> pwd.pw_name = _buf;
X> skip_period ();
X> pwd.pw_passwd = _buf;
X> skip_period ();
X> pwd.pw_uid = atoi (_buf);
X> skip_period ();
X> pwd.pw_gid = atoi (_buf);
X> skip_period ();
X> pwd.pw_gecos = _buf;
X> skip_period ();
X> pwd.pw_dir = _buf;
X> skip_period ();
X> pwd.pw_shell = _buf;
X102c102
X< if (!strcmp (pwd -> name, name))
X---
X> if (!strcmp (pwd -> pw_name, name))
X118c118
X< if (pwd -> uid == uid)
X---
X> if (pwd -> pw_uid == uid)
+ END-OF-FILE lib:getpwent.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\g\e\t\p\w\e\n\t\.\c
set `sum \l\i\b\:\g\e\t\p\w\e\n\t\.\c`
sum=$1
case $sum in
09719) :;;
*) echo 'Bad sum in '\l\i\b\:\g\e\t\p\w\e\n\t\.\c >&2
esac
echo Extracting \l\i\b\:\m\a\l\l\o\c\.\c
sed 's/^X//' > \l\i\b\:\m\a\l\l\o\c\.\c << '+ END-OF-FILE '\l\i\b\:\m\a\l\l\o\c\.\c
X84,88c84,105
X< free(p)
X< char *p;
X< {
X< * (vir_bytes *) (p - sizeof(char *)) &= ~BUSY;
X< }
X---
X> char *calloc(m,size)
X> unsigned m,size;
X> {
X> char *malloc();
X> char *cp;
X> register int i;
X> register char *temp;
X>
X> i = m*size;
X> if ((cp=malloc(i))==(char *)0) return (char *)0;
X>
X> /* malloc succeeded--clear allocated memory */
X> for (temp = cp ; i-- ; ) *temp++ = '\0';
X> return cp;
X> }
X>
X>
X> free(p)
X> char *p;
X> {
X> * (vir_bytes *) (p - sizeof(char *)) &= ~BUSY;
X> }
+ END-OF-FILE lib:malloc.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\m\a\l\l\o\c\.\c
set `sum \l\i\b\:\m\a\l\l\o\c\.\c`
sum=$1
case $sum in
23606) :;;
*) echo 'Bad sum in '\l\i\b\:\m\a\l\l\o\c\.\c >&2
esac
echo Extracting \l\i\b\:\p\r\i\n\t\k\.\c
sed 's/^X//' > \l\i\b\:\p\r\i\n\t\k\.\c << '+ END-OF-FILE '\l\i\b\:\p\r\i\n\t\k\.\c
X2c2
X< * system itself, and should never be included in user programs. The name
X---
X> * system itself, and should never be included in user programs. The name
X15a16
X> char **pp;
X33a35
X> pp = (char **) valp;
X43c45
X< case 's': p = (char *) *valp++;
X---
X> case 's': p = *pp++; valp = (int *) pp;
+ END-OF-FILE lib:printk.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\p\r\i\n\t\k\.\c
set `sum \l\i\b\:\p\r\i\n\t\k\.\c`
sum=$1
case $sum in
60538) :;;
*) echo 'Bad sum in '\l\i\b\:\p\r\i\n\t\k\.\c >&2
esac
echo Extracting \l\i\b\:\p\u\t\c\.\c
sed 's/^X//' > \l\i\b\:\p\u\t\c\.\c << '+ END-OF-FILE '\l\i\b\:\p\u\t\c\.\c
X41,43c41,43
X< return(0);
X< }
X<
X---
X> return(ch & CMASK);
X> }
X>
+ END-OF-FILE lib:putc.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\p\u\t\c\.\c
set `sum \l\i\b\:\p\u\t\c\.\c`
sum=$1
case $sum in
30324) :;;
*) echo 'Bad sum in '\l\i\b\:\p\u\t\c\.\c >&2
esac
echo Extracting \l\i\b\:\r\u\n
sed 's/^X//' > \l\i\b\:\r\u\n << '+ END-OF-FILE '\l\i\b\:\r\u\n
X1,8c1,68
X< for i in *.s
X< do as -o `basename $i .s`.o $i
X< done
X< for i in *.c
X< do cc -c -O $i
X< done
X< ar r lib.a `lorder *.o | tsort 2>/dev/null`
X< echo "lib.a done."
X---
X> # ========== compile everything ===========
X> for i in *.c
X> do
X> echo $i
X> cc -c -LIB $i
X> done
X>
X>
X> # ========== build library ==============
X> #
X> # Build libc.a using all of the .s files in the current directory.
X> # New files are placed at the beginning of the library followed by
X> # modules which are already in the old library (/usr/lib/libc.a).
X> # Old modules are placed in the new library in the same order in which
X> # they appear in the old library.
X> #
X> # Art Zemon, July 17, 1987
X> #
X> echo Reading old library
X> ar t /usr/lib/libc.a > list
X> split -8 list
X> cat /dev/null > orig.order
X> echo Creating orig.order
X> for f in x??
X> do
X> echo ar a libc.a `cat $f` >> orig.order
X> rm $f
X> done
X>
X> #
X> # Figure out which files are not in the existing library.
X> # Base this decision on the .c files because there are a couple of .s
X> # files here which don't belong in the library.
X> #
X> echo Checking .c files
X> cat /dev/null > new.files
X> for c in *.c
X> do
X> f=`basename $c .c`.s
X> echo $f
X> if grep -s $f list > /dev/null 2>&1 ; then cat /dev/null ; else echo ar av libc.a $f >> new.files ; fi
X> done
X>
X> #
X> # Figure out which modules are in the library but not here and extract them
X> # from the library.
X> #
X> echo determining which modules must be extracted from old library
X> rm -f libc.a
X> sh orig.order > /dev/null 2> missing
X> ar xv /usr/lib/libc.a `grep 'Cannot find ' missing | gres 'Cannot find ' ''`
X> rm missing libc.a list
X>
X> #
X> # Construct the library
X> #
X> echo constructing new library with new modules
X> sh new.files
X> echo appending original modules to new library
X> sh orig.order
X> echo done
X> --
X> -- Art Zemon
X> FileNet Corporation
X> Costa Mesa, California
X> ...!hplabs!felix!zemon
X>
X>
+ END-OF-FILE lib:run
chmod 'u=rw,g=r,o=r' \l\i\b\:\r\u\n
set `sum \l\i\b\:\r\u\n`
sum=$1
case $sum in
35638) :;;
*) echo 'Bad sum in '\l\i\b\:\r\u\n >&2
esac
echo Extracting \l\i\b\:\s\c\a\n\f\.\c
sed 's/^X//' > \l\i\b\:\s\c\a\n\f\.\c << '+ END-OF-FILE '\l\i\b\:\s\c\a\n\f\.\c
X3c3
X< #include <stdio.h>
X---
X> #include "stdio.h"
X74c74
X< static index(ch, string)
X---
X> static scnindex(ch, string)
X292c292
X< (index (ic, format) ^ reverse)) {
X---
X> (scnindex (ic, format) ^ reverse)) {
+ END-OF-FILE lib:scanf.c
chmod 'u=rw,g=r,o=r' \l\i\b\:\s\c\a\n\f\.\c
set `sum \l\i\b\:\s\c\a\n\f\.\c`
sum=$1
case $sum in
35529) :;;
*) echo 'Bad sum in '\l\i\b\:\s\c\a\n\f\.\c >&2
esac
echo Extracting \m\m\:\f\o\r\k\e\x\i\t\.\c
sed 's/^X//' > \m\m\:\f\o\r\k\e\x\i\t\.\c << '+ END-OF-FILE '\m\m\:\f\o\r\k\e\x\i\t\.\c
X27a28
X> PRIVATE process_group = 1; /* next process grp to be assigned */
X81a83,85
X> /* Set process group. */
X> if (who == INIT_PROC_NR) rmc->mp_procgrp = process_group++;
X>
+ END-OF-FILE mm:forkexit.c
chmod 'u=rw,g=r,o=r' \m\m\:\f\o\r\k\e\x\i\t\.\c
set `sum \m\m\:\f\o\r\k\e\x\i\t\.\c`
sum=$1
case $sum in
38716) :;;
*) echo 'Bad sum in '\m\m\:\f\o\r\k\e\x\i\t\.\c >&2
esac
echo Extracting \m\m\:\m\a\k\e\.\b\a\t
sed 's/^X//' > \m\m\:\m\a\k\e\.\b\a\t << '+ END-OF-FILE '\m\m\:\m\a\k\e\.\b\a\t
X9d8
X< echo (e.g. after a manual compilation of a module).
+ END-OF-FILE mm:make.bat
chmod 'u=rw,g=r,o=r' \m\m\:\m\a\k\e\.\b\a\t
set `sum \m\m\:\m\a\k\e\.\b\a\t`
sum=$1
case $sum in
49173) :;;
*) echo 'Bad sum in '\m\m\:\m\a\k\e\.\b\a\t >&2
esac
echo Extracting \m\m\:\m\a\k\e\f\i\l\e
sed 's/^X//' > \m\m\:\m\a\k\e\f\i\l\e << '+ END-OF-FILE '\m\m\:\m\a\k\e\f\i\l\e
X9,12c9,14
X< @echo "Start linking MM. /lib/cem will be removed to make space on RAM disk"
X< @rm -f /lib/cem /tmp/*
X< @asld -o mm $l/head.s $(obj) $l/libc.a $l/end.s
X< @echo "MM done. Please restore /lib/cem manually"
X---
X> @echo "Start linking MM."
X> @echo "If RAM disk fills up, edit makefile to use asld -T. "
X> @echo "On a PC, /lib/* will be removed to make space on RAM disk"
X> @rm -f /lib/cem /tmp/*
X> @asld -o mm $l/head.s $(obj) $l/libc.a $l/end.s
X> @echo "MM done. On a PC, please restore /lib/cem manually"
+ END-OF-FILE mm:makefile
chmod 'u=rw,g=r,o=r' \m\m\:\m\a\k\e\f\i\l\e
set `sum \m\m\:\m\a\k\e\f\i\l\e`
sum=$1
case $sum in
20778) :;;
*) echo 'Bad sum in '\m\m\:\m\a\k\e\f\i\l\e >&2
esac
echo Extracting \m\m\:\s\i\g\n\a\l\.\c
sed 's/^X//' > \m\m\:\s\i\g\n\a\l\.\c << '+ END-OF-FILE '\m\m\:\s\i\g\n\a\l\.\c
X102a103
X> mp->mp_procgrp = rmp->mp_procgrp; /* get process group right */
X116c117,118
X< id = (i+1 == SIGINT || i+1 == SIGQUIT ? 0 : proc_id);
X---
X> id= (i+1 == SIGINT || i+1 == SIGQUIT ? 0 : proc_id);
X> if (i + 1 == SIGKILL) id = -1; /* simulate kill -1 9 */
X257c259
X< m_sig.PROC_NR = proc_nr;
X---
X> m_sig.CLOCK_PROC_NR = proc_nr;
X344c346,349
X< if (rmp->mp_realuid != rmp->mp_effuid) return;
X---
X> if (rmp->mp_realuid != rmp->mp_effuid) {
X> tell_fs(CHDIR, 0, 1, 0); /* go back to MM's directory */
X> return;
X> }
+ END-OF-FILE mm:signal.c
chmod 'u=rw,g=r,o=r' \m\m\:\s\i\g\n\a\l\.\c
set `sum \m\m\:\s\i\g\n\a\l\.\c`
sum=$1
case $sum in
58516) :;;
*) echo 'Bad sum in '\m\m\:\s\i\g\n\a\l\.\c >&2
esac
echo Extracting \t\o\o\l\s\:\b\o\o\t\b\l\o\k
sed 's/^X//' > \t\o\o\l\s\:\b\o\o\t\b\l\o\k << '+ END-OF-FILE '\t\o\o\l\s\:\b\o\o\t\b\l\o\k
X62,63c62,63
X< mov ss,ax | set ss to 0
X< mov sp,#1024 | initialize sp (top of vector table)
X---
X> mov ss,dx | set ss to cs i.e., stack in high core
X> mov sp,#1536 | initialize sp to high core
X222c222
X< greet: .asciz "\rBooting MINIX 1.1\r\n"
X---
X> greet: .asciz "\rBooting MINIX 1.2. Copyright 1987 Prentice-Hall, Inc.\r\n"
+ END-OF-FILE tools:bootblok
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\b\o\o\t\b\l\o\k
set `sum \t\o\o\l\s\:\b\o\o\t\b\l\o\k`
sum=$1
case $sum in
55015) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\b\o\o\t\b\l\o\k >&2
esac
echo Extracting \t\o\o\l\s\:\c\h\a\n\g\e\m\e
sed 's/^X//' > \t\o\o\l\s\:\c\h\a\n\g\e\m\e << '+ END-OF-FILE '\t\o\o\l\s\:\c\h\a\n\g\e\m\e
X1,44c1,39
X< : The default stack size is 1K. The following commands need more.
X< b=../commands/bin
X< t=../test
X< chmem =2000 $b/cc
X< chmem =2000 $b/time
X< chmem =2000 $b/tail
X< chmem =40000 $b/cpp
X< chmem =52000 $b/cem
X< chmem =20000 $b/opt
X< chmem =30000 $b/cg
X< chmem =30000 $b/sort
X< chmem =30000 $b/asld
X< chmem =16000 $b/mkfs
X< chmem =8000 $b/dd
X< chmem =8000 $b/rmdir
X< chmem =8000 $b/mkdir
X< chmem =32000 $b/dosread
X< chmem =20000 $b/make
X< chmem =8000 $b/gres
X< chmem =8000 $b/grep
X< chmem =8000 $b/sh
X< chmem =8000 $b/gres
X< chmem =8000 $b/mv
X< chmem =8000 $b/rm
X< chmem =8000 $b/pr
X< chmem =64000 $b/libpack
X< chmem =64000 $b/libupack
X< chmem =64000 $b/mined
X< chmem =8000 $t/test0
X< chmem =8000 $t/test1
X< chmem =8000 $t/test2
X< chmem =8000 $t/test3
X< chmem =8000 $t/test4
X< chmem =8000 $t/test5
X< chmem =8000 $t/test6
X< chmem =8000 $t/test7
X< chmem =8000 $t/test8
X< chmem =8000 $t/test9
X< chmem =8000 $t/test10
X< chmem =8000 $t/test11
X< chmem =8000 $t/t10a
X< chmem =8000 $t/t11a
X< chmem =8000 $t/t11b
X< chmem =8000 $b/df
X---
X> : Increase default stack size from 2K.
X> b=../commands/bin
X> t=../test
X> chmem =30000 $b/asld
X> chmem =2000 $b/cc
X> chmem =52000 $b/cem
X> chmem =30000 $b/cg
X> chmem =32000 $b/cpdir
X> chmem =40000 $b/cpp
X> chmem =40000 $b/dd
X> chmem =50000 $b/diff
X> chmem =8000 $b/df
X> chmem =32000 $b/dosread
X> chmem =50000 $b/find
X> chmem =50000 $b/fix
X> chmem =8000 $b/grep
X> chmem =8000 $b/gres
X> chmem =64000 $b/libpack
X> chmem =64000 $b/libupack
X> chmem =20000 $b/make
X> chmem =64000 $b/mined
X> chmem =8000 $b/mkdir
X> chmem =16000 $b/mkfs
X> chmem =8000 $b/mv
X> chmem =20000 $b/opt
X> chmem =8000 $b/pr
X> chmem =50000 $b/readfs
X> chmem =8000 $b/rm
X> chmem =8000 $b/rmdir
X> chmem =8000 $b/sh
X> chmem =30000 $b/sort
X> chmem =2000 $b/tail
X> chmem =2000 $b/time
X> chmem =8000 $t/t10a
X> chmem =8000 $t/t11a
X> chmem =8000 $t/t11b
X> for i in 1 2 3 4 5 6 7 8 9 10
X> do chmem =8000 ../test/test$i
X> done
+ END-OF-FILE tools:changeme
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\c\h\a\n\g\e\m\e
set `sum \t\o\o\l\s\:\c\h\a\n\g\e\m\e`
sum=$1
case $sum in
53481) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\c\h\a\n\g\e\m\e >&2
esac
echo Extracting \t\o\o\l\s\:\m\a\k\e\f\i\l\e
sed 's/^X//' > \t\o\o\l\s\:\m\a\k\e\f\i\l\e << '+ END-OF-FILE '\t\o\o\l\s\:\m\a\k\e\f\i\l\e
X40,41d39
X< mkfs.s: mkfs.c
X< cc -c -DUNIX mkfs.c
X45c43
X< asld -o fsck fsck1.s fsck.s $l/libc.a $l/end.s
X---
X> asld -o fsck -T. fsck1.s fsck.s $l/libc.a $l/end.s
X58,59c56
X< @echo "Insert blank disk in drive 0 and hit return"
X< @getlf
X---
X> @getlf "Insert blank diskette in drive 0 and hit return"
X69,71c66,67
X< @echo insert blank disk in drive 0 and hit return
X< @getlf
X< mkfs -l /dev/fd0 proto.usr >log.usr
X---
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.usr >log.usr
X75,77c71,72
X< @echo insert blank disk in drive 0 and hit return
X< @getlf
X< mkfs -l /dev/fd0 proto.user >log.user
X---
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.user >log.user
X85,87c80,136
X< @echo "insert blank disk in drive 0 and hit return"
X< mkfs -l /dev/fd0 proto.ram >log.ram
X< getlf
X---
X> @getlf "Insert blank disk in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.ram >log.ram
X>
X> # Make the distribution disks.
X> disk5: mkfs proto.disk5
X> /etc/umount /dev/fd0
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.disk5 >log.disk5
X>
X> disk6: mkfs proto.disk6
X> /etc/umount /dev/fd0
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.disk6 >log.disk6
X>
X> disk7: mkfs proto.disk7
X> @rm -rf proto.a misc.a >/dev/null
X> ar r proto.a proto.*
X> ar r misc.a passwd rc ttys profile
X> /etc/umount /dev/fd0
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.disk7 >log.disk7
X>
X> disk8: mkfs proto.disk8
X> /etc/umount /dev/fd0
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.disk8 >log.disk8
X>
X> disk9: mkfs proto.disk9
X> /etc/umount /dev/fd0
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/fd0 proto.disk9 >log.disk9
X>
X> at.ram: mkfs proto.at.ram
X> if /etc/umount /dev/at0; then : ; else : ; fi
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/at0 proto.at.ram >log.at.ram
X>
X> at.usr: mkfs proto.at.usr
X> if /etc/umount /dev/at0; then : ; else : ; fi
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/at0 proto.at.usr >log.at.usr
X>
X> at.disk4: mkfs proto.at.disk4
X> if /etc/umount /dev/at0; then : ; else : ; fi
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/at0 proto.at.disk4 >log.at.disk4
X>
X> at.disk5: mkfs proto.at.disk5
X> if /etc/umount /dev/at0; then : ; else : ; fi
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/at0 proto.at.disk5 >log.at.disk5
X>
X> at.disk6: mkfs proto.at.disk6
X> if /etc/umount /dev/at0; then : ; else : ; fi
X> @getlf "Insert blank diskette in drive 0 and hit return"
X> mkfs -dL /dev/at0 proto.at.disk6 >log.at.disk6
X>
+ END-OF-FILE tools:makefile
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\m\a\k\e\f\i\l\e
set `sum \t\o\o\l\s\:\m\a\k\e\f\i\l\e`
sum=$1
case $sum in
21270) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\m\a\k\e\f\i\l\e >&2
esac
echo Extracting \t\o\o\l\s\:\p\r\o\t\o\.\a\t
sed 's/^X//' > \t\o\o\l\s\:\p\r\o\t\o\.\a\t << '+ END-OF-FILE '\t\o\o\l\s\:\p\r\o\t\o\.\a\t
X45,51c45
X< test d--755 2 1
X< $
X< commands d--755 2 1
X< $
X< doc d--755 2 1
X< $
X< $
X---
X> $
+ END-OF-FILE tools:proto.at
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\p\r\o\t\o\.\a\t
set `sum \t\o\o\l\s\:\p\r\o\t\o\.\a\t`
sum=$1
case $sum in
65198) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\p\r\o\t\o\.\a\t >&2
esac
echo Extracting \t\o\o\l\s\:\p\r\o\t\o\.\d\i
sed 's/^X//' > \t\o\o\l\s\:\p\r\o\t\o\.\d\i << '+ END-OF-FILE '\t\o\o\l\s\:\p\r\o\t\o\.\d\i
X29,31c29,31
X< lpr.c ---644 2 1 ../commands/lpr.c
X< ls.c ---644 2 1 ../commands/ls.c
X< make.c ---644 2 1 ../commands/make.c
X---
X> login.c ---644 2 1 ../commands/login.c
X> lpr.c ---644 2 1 ../commands/lpr.c
X> ls.c ---644 2 1 ../commands/ls.c
X65d64
X< changemem ---644 2 1 changemem
X72c71
X< makefile ---644 2 1 ../commands/makefile
X---
X> makefile ---644 2 1 ../commands/PCIX/makefile
X78c77,91
X< $
X---
X> include d--777 2 1
X> blocksize.h ---644 2 1 ../include/blocksize.h
X> ctype.h ---644 2 1 ../include/ctype.h
X> errno.h ---644 2 1 ../include/errno.h
X> grp.h ---644 2 1 ../include/grp.h
X> lib.h ---644 2 1 ../include/lib.h
X> pwd.h ---644 2 1 ../include/pwd.h
X> regexp.h ---644 2 1 ../include/regexp.h
X> setjmp.h ---644 2 1 ../include/setjmp.h
X> sgtty.h ---644 2 1 ../include/sgtty.h
X> signal.h ---644 2 1 ../include/signal.h
X> stat.h ---644 2 1 ../include/stat.h
X> stdio.h ---644 2 1 ../include/stdio.h
X> $
X> $
+ END-OF-FILE tools:proto.di
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\p\r\o\t\o\.\d\i
set `sum \t\o\o\l\s\:\p\r\o\t\o\.\d\i`
sum=$1
case $sum in
14581) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\p\r\o\t\o\.\d\i >&2
esac
echo Extracting \t\o\o\l\s\:\p\r\o\t\o\.\u\s
sed 's/^X//' > \t\o\o\l\s\:\p\r\o\t\o\.\u\s << '+ END-OF-FILE '\t\o\o\l\s\:\p\r\o\t\o\.\u\s
X8,71c8,68
X< ar ---755 2 1 ../commands/bin/ar
X< asld ---755 2 1 ../commands/bin/asld
X< basename ---755 2 1 ../commands/bin/basename
X< chmem ---755 2 1 ../commands/bin/chmem
X< chmod ---755 2 1 ../commands/bin/chmod
X< chown ---755 2 1 ../commands/bin/chown
X< clr ---755 2 1 ../commands/bin/clr
X< cmp ---755 2 1 ../commands/bin/cmp
X< comm ---755 2 1 ../commands/bin/comm
X< date ---755 2 1 ../commands/bin/date
X< dd ---755 2 1 ../commands/bin/dd
X< df -u-755 0 1 ../commands/bin/df
X< dosread ---755 2 1 ../commands/bin/dosread
X< echo ---755 2 1 ../commands/bin/echo
X< grep ---755 2 1 ../commands/bin/grep
X< head ---755 2 1 ../commands/bin/head
X< libpack ---755 2 1 ../commands/bin/libpack
X< libupack ---755 2 1 ../commands/bin/libupack
X< ln ---755 2 1 ../commands/bin/ln
X< login ---755 2 1 ../commands/bin/login
X< lpr ---755 2 1 ../commands/bin/lpr
X< make ---755 2 1 ../commands/bin/make
X< mkfs ---755 2 1 ../commands/bin/mkfs
X< mknod ---755 2 1 ../commands/bin/mknod
X< mv ---755 2 1 ../commands/bin/mv
X< od ---755 2 1 ../commands/bin/od
X< passwd -u-755 0 1 ../commands/bin/passwd
X< pr ---755 2 1 ../commands/bin/pr
X< pwd ---755 2 1 ../commands/bin/pwd
X< rmdir -u-755 0 1 ../commands/bin/rmdir
X< size ---755 2 1 ../commands/bin/size
X< sleep ---755 2 1 ../commands/bin/sleep
X< sort ---755 2 1 ../commands/bin/sort
X< split ---755 2 1 ../commands/bin/split
X< stty ---755 2 1 ../commands/bin/stty
X< su -u-755 0 1 ../commands/bin/su
X< sum ---755 2 1 ../commands/bin/sum
X< tail ---755 2 1 ../commands/bin/tail
X< tee ---755 2 1 ../commands/bin/tee
X< time ---755 2 1 ../commands/bin/time
X< touch ---755 2 1 ../commands/bin/touch
X< tr ---755 2 1 ../commands/bin/tr
X< true ---755 2 1 ../commands/bin/true
X< uniq ---755 2 1 ../commands/bin/uniq
X< wc ---755 2 1 ../commands/bin/wc
X< $
X< include d--755 2 1
X< blocksize.h ---644 2 1 ../include/blocksize.h
X< errno.h ---644 2 1 ../include/errno.h
X< sgtty.h ---644 2 1 ../include/sgtty.h
X< signal.h ---644 2 1 ../include/signal.h
X< stat.h ---644 2 1 ../include/stat.h
X< setjmp.h ---644 2 1 ../include/setjmp.h
X< stdio.h ---644 2 1 ../include/stdio.h
X< $
X< lib d--755 2 1
X< cg ---755 2 1 ../commands/bin/cg
X< opt ---755 2 1 ../commands/bin/opt
X< crtso.s ---755 2 1 ../lib/MINIX/crtso.s
X< end.s ---755 2 1 ../lib/MINIX/end.s
X< head.s ---755 2 1 ../lib/MINIX/head.s
X< libc.a ---755 2 1 ../commands/bin/libc.a
X< $
X< $
X---
X> ar ---755 2 1 ../commands/bin/ar
X> asld ---755 2 1 ../commands/bin/asld
X> basename ---755 2 1 ../commands/bin/basename
X> chmem ---755 2 1 ../commands/bin/chmem
X> chmod ---755 2 1 ../commands/bin/chmod
X> chown ---755 2 1 ../commands/bin/chown
X> clr ---755 2 1 ../commands/bin/clr
X> cmp ---755 2 1 ../commands/bin/cmp
X> comm ---755 2 1 ../commands/bin/comm
X> date ---755 2 1 ../commands/bin/date
X> dd ---755 2 1 ../commands/bin/dd
X> df -u-755 0 1 ../commands/bin/df
X> dosread ---755 2 1 ../commands/bin/dosread
X> echo ---755 2 1 ../commands/bin/echo
X> grep ---755 2 1 ../commands/bin/grep
X> head ---755 2 1 ../commands/bin/head
X> ln ---755 2 1 ../commands/bin/ln
X> login ---755 2 1 ../commands/bin/login
X> lpr ---755 2 1 ../commands/bin/lpr
X> make ---755 2 1 ../commands/bin/make
X> mkfs ---755 2 1 ../commands/bin/mkfs
X> mknod ---755 2 1 ../commands/bin/mknod
X> mv -u-755 0 1 ../commands/bin/mv
X> od ---755 2 1 ../commands/bin/od
X> pr ---755 2 1 ../commands/bin/pr
X> pwd ---755 2 1 ../commands/bin/pwd
X> rmdir -u-755 0 1 ../commands/bin/rmdir
X> size ---755 2 1 ../commands/bin/size
X> sleep ---755 2 1 ../commands/bin/sleep
X> sort ---755 2 1 ../commands/bin/sort
X> split ---755 2 1 ../commands/bin/split
X> stty ---755 2 1 ../commands/bin/stty
X> su -u-755 0 1 ../commands/bin/su
X> sum ---755 2 1 ../commands/bin/sum
X> tail ---755 2 1 ../commands/bin/tail
X> tee ---755 2 1 ../commands/bin/tee
X> time ---755 2 1 ../commands/bin/time
X> touch ---755 2 1 ../commands/bin/touch
X> tr ---755 2 1 ../commands/bin/tr
X> true ---755 2 1 ../commands/bin/true
X> uniq ---755 2 1 ../commands/bin/uniq
X> wc ---755 2 1 ../commands/bin/wc
X> $
X> include d--755 2 1
X> blocksize.h ---644 2 1 ../include/blocksize.h
X> errno.h ---644 2 1 ../include/errno.h
X> sgtty.h ---644 2 1 ../include/sgtty.h
X> signal.h ---644 2 1 ../include/signal.h
X> stat.h ---644 2 1 ../include/stat.h
X> setjmp.h ---644 2 1 ../include/setjmp.h
X> stdio.h ---644 2 1 ../include/stdio.h
X> $
X> lib d--755 2 1
X> cg ---755 2 1 ../commands/bin/cg
X> opt ---755 2 1 ../commands/bin/opt
X> crtso.s ---755 2 1 ../lib/MINIX/crtso.s
X> end.s ---755 2 1 ../lib/MINIX/end.s
X> head.s ---755 2 1 ../lib/MINIX/head.s
X> libc.a ---755 2 1 ../commands/bin/libc.a
X> $
X> $
+ END-OF-FILE tools:proto.us
chmod 'u=rw,g=r,o=r' \t\o\o\l\s\:\p\r\o\t\o\.\u\s
set `sum \t\o\o\l\s\:\p\r\o\t\o\.\u\s`
sum=$1
case $sum in
09029) :;;
*) echo 'Bad sum in '\t\o\o\l\s\:\p\r\o\t\o\.\u\s >&2
esac
exit 0
|