> I notice when programmers write books they tend to write them using
> troff/nroff/groff with pic, eqn, etc to do various things.
>
> % troff myfile.troff > myfile.ps
Others have pointed out -Tps, but if you go
groff myfile.troff > myfile.ps
you'll get postscript by default. Also, I think
some default page sizes may be US letter, which you may not want.
Yes, real programmers use troff, most famously W.R. Stevens
with his 'Unix Network Programming', and 'TCP/IP Illustrated'.
I wrote a review of his books and sent him a copy. The review originally
from the Australian AUUG column, is tacked on below; well because I
re-read it and liked it.
(Actually some of my views have changed. I would now contemplate using
a scripting language such as Tcl/Tk on both client and server)
Stevens really 'wrote the book' in these areas. His death is a great loss.
Jamie
-------------------------------------------------------
One of the current buzz-phrases in the computer world
is `client-server'. It remains to be seen whether this particular
phrase lasts long enough to make it into the Macquarie dictionary.
The typical situation of a client-server setup is a Unix host connected
to multiple Window's based PC's. I have always suspected that this
particular setup is to cover up the fact that the Unix host is actually
doing all the work, and the PCs are simply `Window-dressing'.
In the past, the PCs would have been terminals, but these are not
flashy enough for the modern corporate environment.
Typically the Unix host is running a database system, and the PCs are
running `front end' software based on tools such as PowerBuilder.
The PCs connect to the database for data entry and queries.
This works well enough for many applications, but there often comes
a time when these tools aren't enough to do the job. The Usenet
newsgroup comp.client-server, which is devoted solely to this topic,
has many articles with tales of woe. In fact, one wag has it that C/S
doesn't stand for client server but Continuous Sweating. Apart from
issues such as configuring and keeping the software on multiple PCs
up to date, there are performance questions, often with the use
of database stored procedures.
One recurring problem is when the host database simply can't
do the job, but a specialised Unix process will do the trick.
This situation can still be described as client-server, but with the
difference that someone is going to have to get their `hands dirty' with
programming, both on the PC side and on the Unix host side. That somebody
is the humble programmer.
Typically, the PC side can have software written that interfaces to the
standard `Winsock' interface. This software can take the form of a
Windows' DLL, and have hooks that PowerBuilder can still access. On the
Unix host side, the software almost certainly has to use Unix networking
techniques.
There are two invaluable resources for helping to write Unix server
software.
Garth, the complete nerd, mate of Wayne, in the film Wayne's World II, is
seen reading `Unix Network Programming'. Presumably, this is to highlight
Garth's nerdness, although I suspect it's more to appeal to a certain type
of person.
Nerdism is all relative, because I found `Unix Network Programming' far more
interesting than Wayne's World I or II.
The author of `Unix Network Programming', W.R. Stevens has produced four
books so far. All are marvelous books, all aimed at the professional
programmer / system developer. The first two, `Unix Network Programming'
and `Advanced Programming in the Unix Environment', are of particular
relevance in client-server environments.
In book stores full of `Windows Secrets Revealed' (as Wayne and Garth would
say : NOT!), Stevens is the one with the answers. `Unix Network Programming'
takes you through the myriad of features offered by modern Unices to
provide service software in client-server environments.
Stevens' second book `Advanced Programming in the Unix Environment', builds
on the information presented in his first book. Not concerned directly
with network programming, it none the less describes features provided by
Unix that weren't covered in his first book and that are needed to
implement client-server processes.
Stevens has also produced two other books, `TCP/IP Illustrated', Volumes
1 and 2. In a client-server setup, the distant clients have to be
connected by a protocol to the host. The protocol of choice in a
Unix environment (actually, probably any environment) is TCP/IP.
In these two later books, Stevens takes one on a very comprehensive
tour of the protocols. I thought I knew a lot about these protocols,
reading Stevens' books was a very humbling experience.
One interesting aspect of Steven's books is the way they were produced.
Stevens proudly used the humble Unix text processing facility `troff'. All his
diagrams, formulas were typeset using this tool.
Nowhere does this become more of a tour-de-force than in his book, `TCP/IP
Illustrated. Volume 1'. The time diagrams are very interesting, again
typeset using troff and the pic typesetting tool. At first I suspected Stevens
must have developed special software to take trace dumps and format them
into these time diagrams, but after some short email correspondence, the
pedestrian truth that they were done by hand emerged!
It is all very well for an organisation to adopt client-server technology
as a panacea for computer problems. As a way of `getting things done' it
probably represents a realistic way to go. But if you are the hapless
programmer trying to tie the system together, you need all the help you can
get, and Stevens books, kilo for kilo, will outclass any `secrets' book any
day.
--
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://lists.slug.org.au/listinfo/slug