less prints "ESC" instead of escape char

Matthew Reppert repp0017 at tc.umn.edu
Sun Oct 6 12:41:35 PDT 2002


[not on the list, please CC any replies to me]

I recently finished installing my second LFS system (a from-scratch
upgrade of my first one) using the 3.3 book, with a few more up-to-date
packages (procps-2.0.9 from surriel.org, util-linux-2.11u, most recent
autoconf/automake, to name a few). However, less is giving me trouble.

When I view a manpage, I don't get any of the usual highlight sequences.
Instead, less dumps the text of the escape sequence straight to the
terminal ... EXCEPT for the all-important escape itself. This shows up
as a reverse-video "ESC". For example, the terminfo manpage looks like:

TERMINFO(5)                     File Formats                  
TERMINFO(5)

ESC[1mNAMEESC[0m
         terminfo - terminal capability data base

ESC[1mSYNOPSISESC[0m
         /usr/share/terminfo/*/*
[ pages of this unreadable borkage ... ]

My terminal settings appear to be correct. lynx and vim both work 
perfectly
fine. ls colors work. In fact, if I do (eg)
'nroff -mandoc < /usr/share/man/man5/terminfo.5' it gets output to 
stdout with
the formatting and highlights just as I would expect them to be. If I 
feed it
to less, or do the corresponding 'man terminfo', I get a screen full of
manpage text, color sequences, and reverse-video "ESC"s. The spacing is
all correct, it's just that it doesn't appear to handle ESC correctly.
Also, the less binary from my OLD system (where manpages -did- work) 
also
displays ESC like this if I run it from the new system. (This is all on
tty[1-6] with TERM=linux)

BUT. If I do a 'less --help', it outputs its help screen perfectly.
Eg, the "SUMMARY OF LESS COMMANDS" at the top is highlighted bright 
white,
with the "Commands marked ... " below it in lightgrey. So less -can-
do the right thing ... it just won't.

Any thoughts? The upgrade has been great (especially X 4.2.1, I now have
working TV-in), but a system without working manpages is a non-working
system as far as I'm concerned ...

Thanks!
Matt

-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-support' in the subject header of the message



More information about the lfs-support mailing list