NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: bin/1904
The following reply was made to PR bin/1904; it has been noted by GNATS.
From: David Holland <dholland-bugs%netbsd.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: bin/1904
Date: Sun, 29 May 2016 22:31:20 +0000
On Sun, May 29, 2016 at 08:30:00PM +0000, Abhinav Upadhyay wrote:
> > Maybe; ISTM that the way to deal with man.conf is that it should use
> > man(1) to generate the cat pages. Except for that man(1) needs a way
> > to be told "please print this page" and while I thought it had an
> > option for that, it doesn't currently seem to.
>
> We could do that, mandoc has -Tascii option (I assume that's
> equivalent to a cat page output, correct me if I'm wrong)
It is. What I meant was something like "man -Q /some/path/foo.1" to
print /some/path/foo.1 directly rather than search for a page by name.
Like I said, I remember man having such an option but that must have
been on some other platform long ago.
Anyway, more careful inspection of catman shows that it's had man.conf
support since 1999. The only thing left in this PR is the support for
hardlinked man pages... the patch here doesn't even begin to apply
because the 1999 changes were a big rewrite, and the logic in this
patch for identifying hardlinks does O(n^2) directory reads, which is
neither necessary nor desirable. So I don't think we should bother
with the amount of work it'll take to merge it.
If anyone wants to implement hardlink handling it seems fairly
straightforward in the current catman code to add a structure to hold
a (fsid, ino) -> name mapping, to add to it when handling a page whose
linkcount > 1, and to check it when encountering a page whose
linkcount > 1. It doesn't seem to me to be worth the trouble given
that we don't even build cat pages by default and with mandoc there's
really no reason to except on the slowest of slow machines.
I've added a note in catman(8) about how to do this in case anyone
sees fit to bother.
In the meantime I see no reason to keep this PR open.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index