ioctl and friends

Dan Jacobowitz drow@false.org
Thu Jul 23 18:05:00 GMT 1998


All right, I have a little problem...

The pre 2.1 glibc redeclares its own versions of just about all system
structs, and most porting headaches can be fixed with a few simple
header switches.  But, the size and contents of struct termios have
changed - and on the powerpc, the changes mean that the size of the
struct has changed from what the kernel expects it to be.  So any ioctl
based on termios fails - that's TCGETS and TCGETA.  Do people think it
would be worthwhile to check for these ioctl()s specifically and
convert?  As it is, it's a pain tracking down every use of ioctls based
on termios and converting to tcgetattr() when the program needs to
compile on multiple (very multiple) versions of linux; I know that it's
not hard, but it's certainly a nasty pitfall that I think could be
avoided without too much trouble.

Dan



More information about the Libc-alpha mailing list