[comp.os.coherent] Where is FIOCLEX defined?

C.R.Harding@massey.ac.nz (C.R. Harding) (05/30/91)

Is there anyone who's played with porting Cnews to Coherent who can help
me? I've got what I presume is the latest version of cnews
(cnews-24-mar-1991.tar.Z or something) and I'm trying to get it running.

After fixing some of the "gotchas" in the cnews shell scripts in a few
nights of work, I managed to get to the point where I can actually start
trying to compile things (well, where doit.bin can start compiling
things). Lo and behold, no sooner does it hit the first cc command line
when it bombs out, saying FIOCLEX is undefined. I checked ioctl() in the
Lexicon, which mentions FIOCLEX and FIONCLEX, but doesn't say where
they're defined. I've grepped through /usr/include, I've grepped through
the man pages, and I can't find FIOCLEX anywhere! I presume that it
*does* require a definition in an include somewhere, but I can't find
it. It's certainly not in stdio.h and sgtty.h, which are the two
includes in the file I'm trying to compile (clsexec.c). Halp!

Caveats: I'm a complete unix newbie, and pretty much the same with C as
well (although my flatmate and co-conspirator is reasonably clued up on
C). I realise that there are older versions of cnews with the Coherent
porting work already done, but I'm using this as an opportunity to learn
the basics of Coherent the hard way (and so far it's paying off, I've
learnt far more about shell scripts and sed scripts in the last 4 days
than I think I ever wanted to, and I'm starting to lose some of the
MS-DOS-isms and get around Coherent properly).

BTW I'm also taking notes about the problems Coherent has with the
standard cnews distribution. If anyone's interested in the information
when I've got it running (or is that if?) let me know. I also thought we
might want to discuss submitting some comments about problems to the
cnews guys (Henry Spencer and Geoff Collyer) to see if they can take
some of the simpler incompatibilities out where possible.

On a slightly different tack, there's been some discussion here of a
console screen saver. Where on earth is that configured? I'm running
Coherent on a 286 with EGA card and display, and I've left it for hours
without a screen-save. It appears that the people who've had it work are
all using monochrome displays, it may work with mono only.

-- 
Craig Harding                        C.R.Harding@massey.ac.nz
Massey University                    BBS: +64 63 551342 3/12/24
New Zealand       "I keep on telling him there's only one g in crzjgrdwldiwdc"

rmk@rmkhome.UUCP (Rick Kelly) (06/01/91)

In article <1991May29.215507.3557@massey.ac.nz> C.R.Harding@massey.ac.nz (C.R. Harding) writes:
>Is there anyone who's played with porting Cnews to Coherent who can help
>me? I've got what I presume is the latest version of cnews
>(cnews-24-mar-1991.tar.Z or something) and I'm trying to get it running.
>
>After fixing some of the "gotchas" in the cnews shell scripts in a few
>nights of work, I managed to get to the point where I can actually start
>trying to compile things (well, where doit.bin can start compiling
>things). Lo and behold, no sooner does it hit the first cc command line
>when it bombs out, saying FIOCLEX is undefined. I checked ioctl() in the
>Lexicon, which mentions FIOCLEX and FIONCLEX, but doesn't say where
>they're defined. I've grepped through /usr/include, I've grepped through
>the man pages, and I can't find FIOCLEX anywhere! I presume that it
>*does* require a definition in an include somewhere, but I can't find
>it. It's certainly not in stdio.h and sgtty.h, which are the two
>includes in the file I'm trying to compile (clsexec.c). Halp!

Did you check out the /usr/include/sys directory?

>Caveats: I'm a complete unix newbie, and pretty much the same with C as
>well (although my flatmate and co-conspirator is reasonably clued up on
>C). I realise that there are older versions of cnews with the Coherent
>porting work already done, but I'm using this as an opportunity to learn
>the basics of Coherent the hard way (and so far it's paying off, I've
>learnt far more about shell scripts and sed scripts in the last 4 days
>than I think I ever wanted to, and I'm starting to lose some of the
>MS-DOS-isms and get around Coherent properly).

You'll probably find more "gotchas" in the scripts when you start to
receive news and post news.

>BTW I'm also taking notes about the problems Coherent has with the
>standard cnews distribution. If anyone's interested in the information
>when I've got it running (or is that if?) let me know. I also thought we
>might want to discuss submitting some comments about problems to the
>cnews guys (Henry Spencer and Geoff Collyer) to see if they can take
>some of the simpler incompatibilities out where possible.

I have exchanged mail with Henry Spencer, at the time that we decided to
put CNEWS on piggy and at MWC BBS.  He does not want to put in any
Coherent specific changes.  CNEWS is considered to be generic UNIX, and you
just have to adapt it to your system.  Also, if you decide to distribute
your version of CNEWS, it must contain a disclaimer that it is not the original
CNEWS, and that Henry and Geoff are not responsible for any problems found.
Also, the current Coherent CNEWS comes with an installation script, written by
Rick Nickle, that makes it easy to configure and use on Coherent.

I have all the patches through March 1991, and I will be upgrading the
current Coherent CNEWS pretty soon.

>On a slightly different tack, there's been some discussion here of a
>console screen saver. Where on earth is that configured? I'm running
>Coherent on a 286 with EGA card and display, and I've left it for hours
>without a screen-save. It appears that the people who've had it work are
>all using monochrome displays, it may work with mono only.

Yes, the screen blanker only works with Hercules and Mono adapters.

Rick Kelly	rmk@rmkhome.UUCP	frog!rmkhome!rmk	rmk@frog.UUCP