From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,acc74ce4f6528841 X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-07-26 15:01:40 PST Newsgroups: comp.unix.osf.osf1 Path: nntp.gmd.de!Germany.EU.net!news.dfn.de!darwin.sura.net!europa.eng.gtefsd.com!howland.reston.ans.net!cs.utexas.edu!utnut!helios.physics.utoronto.ca!sysmark From: sysmark@helios.physics.utoronto.ca (Mark Bartelt) Subject: Strange (mis)feature of the "man" command (was Re: OSF1 2.0 memory leaks ...) Message-ID: Sender: news@helios.physics.utoronto.ca (News Administrator) Reply-To: mark@cita.toronto.edu Organization: University of Toronto Physics/Astronomy/CITA References: <1994Jul25.194141.5530@datum.nyo.dec.com> Date: Tue, 26 Jul 1994 19:25:45 GMT Earlier today, I wrote ... | I just got an e-mail message from Trin Tantsetthi , | who cleared up the confusion. It turns out that "-terminate" is documented in | the "Xdec" man page, whereas I'd been looking in the "Xserver" man page (which | is, after all, where Frank claimed I'd find it). But to add to the ambiguity, | one observes that "man Xserver" produces a man page which starts out ... | | XSERVER(1) | | NAME | Xserver - X Window System server | | ... whereas "man Xdec" produces one which start out ... | | Xdec(1X) | | NAME | Xdec, Xserver - X Window System server | | ... so one could argue that the "Xdec" man page *is* the (well, is an) Xserver | man page; it's just not the one you get when you type "man Xserver". ... and I thought that was the end of this thread. Until I got a message from Richard Eckman , saying: | Just to add to the confusion, I do get the Xdec page when I type | "man Xserver". The contents of /usr/man/man1/Xserver.1X are: | | .so man1/Xdec.1X | | So, it's more or less a symbolic link to Xdec.1X. Sounds like | you've somehow installed a different Xserver man page compared | with the one that comes standard with OSF/1 v2.0 So I checked, and in fact *our* Xserver.1X contains the same thing as his does! Then I realized that "man Xserver" was actually giving me the MIT X11R5 Xserver man page (which we have in /usr/local/man, since we have vanilla MIT X11R5 for our SunOS users, who want an alternative to the loathsome OpenWindows). At first I thought I must have a MANPATH defined, which had /usr/local/man in front of /usr/share/man. But, no, no MANPATH was defined. After some fussing around, I verified that man -M /usr/share/man Xserver ==> DEC's Xserver man page and man -M /usr/local/man Xserver ==> MIT's Xserver man page but man Xserver ==> MIT's, not DEC's Why? Well, it turns out that the files are named /usr/share/man/man1/Xserver.1X and /usr/local/man/man1/Xserver.1 Despite the fact that /usr/share/man comes before /usr/local/man in the default MANPATH, the "man" command seems to search all the directories for "Xserver.1", before rescanning them again to look for "Xserver.1X". This was easy to check: If I rename /usr/share/man/man1/Xserver.1X to /usr/share/man/man1/Xserver.1 (or, alternatively, /usr/local/man/man1/Xserver.1 to /usr/local/man/man1/Xserver.1X), then "man Xserver" will give DEC's Xserver man page. As long as both man pages have the same name, all is well. Also, if there's an "Xserver.1" in /usr/local/man/cat1, "man Xserver" will pick that one in preference to /usr/share/man/man1/Xserver.1X, though it will choose /usr/share/man/man1/Xserver.1 over /usr/local/man/cat1/Xserver.1, curiously. So, my question is: Is this behavious intentional, or is it a bug? And if the former, what's the rationale? Mark Bartelt 416/978-5619 Canadian Institute for mark@cita.toronto.edu Theoretical Astrophysics mark@cita.utoronto.ca "Sheep not busy being shorn are busy frying" - Dylan, at a NZ lamb barbecue [ singing "It's all right, ma (I'm only bleating)" ]