This .arc file contains MS-DOS executables for three programs which
are very useful for handling updates and patches of programs. These
programs are non-proprietary clones of utilities found on most Unix systems.
Diff is a program that compares two files, and gives a summary of
differences to the standard output. What you see posted to the net as
patches is usually this output.
Patch is a program which does the converse of the diff program; that
is, it takes output from diff, and converts the older file given as
diff input into the newer file that was given to diff.
Ed is similar to the Unix ed. It is necessary for ed to be available
when running patch, as patch calls the ed program.
Each of these programs was posted to Usenet as source code. I compiled
diff with no modifications. Ed was posted as minix source code, and I
was able to port it with only a few changes. Patch was a more substantial
port, as I had to rewrite some of the logic. Now instead of piping output
(for ed commands) directly to ed, I have it so that it buffers it into a
file. When all the patch commands are figured out, it does a call to
system("ed %s < patch.tmp"). I have tested patch on a few context diffs,
but not having had to use (and become familiar with) many options on this
command, I wasn't able to thoroughly test the options. My advice is to check
your files after patching. Running the old and patched files through diff
is a good way to check. Please let me know if you find any bugs. Another
change to patch is that instead of renaming the original file from file.ext
to file.ext.orig, it renames it to o_file.ext to be compatible with DOS.
Similarly, unresolved patch blocks are put into a file beginning with r_.
Finally, I added a function mv to rename a file, since DOS doesn't have
the link function that Unix patch uses.
--Steve Creps,[email protected]
, ...!iuvax!silver!creps,[email protected]