From: Fred Roy <froy@gr.osf.org>
Subject: Re: midi player? & more
Date: Fri, 16 Feb 96 15:47:08 +0100 [thread overview]
Message-ID: <199602161447.JAA23929@postman.osf.org> (raw)
In-Reply-To: <Pine.LNX.3.91.960214150019.20706B-100000@redhat.com>
On Wed, 14 Feb 1996, Erik Troan wrote:
>> Yeah - the Red Hat version is broken, probable for the same reason make is.
>> Unfortunately know one knows quite why make is broken either.
>Oopps. Change all occurences of "make" in the above to "more", and you'll
>get something more sensical.
I did not know that `more' was broken on Red Hat's Linux/Alpha (because
I am still using BLADE_0.3...), but I noticed that BLADE's /bin/more was
looking much to `less'. Anyway I've made some changes inside the source
code for `more' which makes it work on Linux/Alpha (i.e. on BLADE_0.3,
at least). Perhaps I just reivented the wheel...
The source code for `more' I modified comes from the [1994?] Slackware
Linux distribution: util-linux-2.1/text-utils/more.c
Before changes, my port of `more' to Linux/Alpha was waiting for 4 chars
before processing the input (i.e. I had to type "qqqq" to quit).
I first added lines like:
otty.c_lflag &= ~(ICANON|ECHO);
+ otty.c_cc[VMIN] = 1; /* be sure it is 1 */
+ otty.c_cc[VTIME] = 0; /* be sure it is 0 */
without success.
Then I noticed that ioctl() was called with (sometimes) a pointer to a
`struct termio' as 3rd argument, while (on Linux/Alpha/BLADE_0.3)
the Vxx array indexes differed beetween termio.c_cc[] and termios.c_cc[]
... and in system headers VMIN * & co are overriden to suit the
`struct termio' variants only when <termio.h> is included ... and it's
not the case in more.c.
So I've changed in my more.c file all occurences of c_cc[Vxx] by
c_cc[_Vxx] (Vxx in {VKILL, VERASE, VTIME, VMIN}) and now it seems ok.
I don't kwnow if the various <*/termio*.h> and <sys/ioctl.h> headers have
been changed for Linux/Alpha till the BLADE_0.3 release; if not, would
some housekeeping be a good idea ?
fred
next parent reply other threads:[~1996-02-16 14:47 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <Pine.LNX.3.91.960214150019.20706B-100000@redhat.com>
1996-02-16 14:47 ` Fred Roy [this message]
1996-02-16 16:14 ` midi player? & more Erik Troan
1996-02-16 15:46 David Mosberger-Tang
-- strict thread matches above, loose matches on Subject: below --
1996-02-16 19:59 Bob Manson
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox