[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#474052: [checks/manpages]: cannot adjust line, ... issues are not considered on localized man pages



On Mon, Apr 21, 2008 at 03:10:17PM -0700, Russ Allbery wrote:
> Frank Lichtenheld <djpig@debian.org> writes:
> > On Thu, Apr 03, 2008 at 02:03:43AM +0200, Daniel Leidert wrote:
> >> We were wondering, why lintian did not complain with a
> >> manpage-has-errors-from-man warning for a localized manpage, that
> >> showed a "cannot adjust line" warning. The problem seems to be, that
> >> the if-statement, that should avoid the "cannot find numbered
> >> character" warning for localized manpages also excludes the other
> >> issues, although they are IMO not a locale problem. Insteda they are a
> >> GROFF issue, that can be fixed indendent from the locale.
> >> 
> >> I attach the patch to show the problem and the possible fix.
> >
> > I wasn't very specific in my commit message then, but I don't think I
> > added that just for fun. So if we remove it we should confirm that the
> > issues that groff seemed to have with these pages are really gone.
> 
> Colin, could you comment on this?  I vaguely recall that previously man-db
> produced these warnings for Asian man pages or something because it had
> trouble finding break points, but that memory is *very* vague and I may be
> out to lunch.  Is it safe to re-enable these warnings now?

There's still a problem here, I'm afraid: specifically, at the moment
man can only cope with formatting CJK pages if its locale is actually a
real CJK UTF-8 locale. (This is a combination man-db/groff bug, whose
origins are tedious to relate.)

It's fairly easy to reproduce by commenting out these lines and then
running lintian on, say, manpages-zh. You get:

  W: manpages-zh: manpage-has-errors-from-man usr/share/man/zh_CN/man1/autorun.1.gz 49: warning [p 1, 2.5i]: cannot adjust line
  W: manpages-zh: manpage-has-errors-from-man usr/share/man/zh_CN/man1/bash.1.gz 960: warning [p 6, 8.2i]: cannot adjust line
  W: manpages-zh: manpage-has-errors-from-man usr/share/man/zh_CN/man1/chmod.1.gz 33: warning [p 1, 3.8i]: cannot adjust line
  W: manpages-zh: manpage-has-errors-from-man usr/share/man/zh_CN/man1/chown.1.gz 30: warning [p 1, 3.5i]: cannot adjust line

... and so on.

This problem is specific to $lang =~ /^(?:ja|ko|zh)/ and I think should
probably be restricted to those pages. For the moment, that would be
better than Daniel's patch.

The other error, "can't find numbered character", is more plausibly
specific to certain locales. The most common incidence of this was bug
#199422, now fixed. I'm actually quite interested in whether this is
still widespread, so I think it would be useful to consider that as a
warning again.

> (lintian.d.o would probably still lose since it has an old man-db, but we
> do detect that and could disable these for stable man-db.)

Indeed. (Although technically the "can't find numbered character" check
depends on the exact Debian version of groff in use.)

-- 
Colin Watson                                       [cjwatson@debian.org]



Reply to: