Are there OSes which have but not ?
up vote
0
down vote
favorite
I am currently pondering the presence of <sys/termios.h>
on many systems, most of which have a symlink between it and <termios.h>
, musl libc’s being a considerable exception: its <sys/termios.h>
warns you that it’s wrong and to use <termios.h>
instead.
On the BSDs, the actual file is in sys/
and the symlink in /usr/include
, so one might have been historically excused for using this… but, giving that GNU autoconf’s AC_SYS_POSIX_TERMIOS
does not look there (even though the configure.ac
of a program I am looking at does use AC_CHECK_HEADERS([ … sys/termios.h … termios.h …])
, I was wondering:
Is there any system in existence which has <sys/termios.h>
with the usual suspects (tcgetattr
, tcsetattr
, cfgetospeed
and related constants) but not <termios.h>
?
Another piece of software I’m looking at only tries <termios.h
> (both fall back to termio, one even to sgtty…), and I’m now trying to figure out whether I should patch one to also look at <sys/termios.h>
(and probably the autoconf macro, too) or patch the other to not look there because it might be pointless.
c portability autoconf termios
add a comment |
up vote
0
down vote
favorite
I am currently pondering the presence of <sys/termios.h>
on many systems, most of which have a symlink between it and <termios.h>
, musl libc’s being a considerable exception: its <sys/termios.h>
warns you that it’s wrong and to use <termios.h>
instead.
On the BSDs, the actual file is in sys/
and the symlink in /usr/include
, so one might have been historically excused for using this… but, giving that GNU autoconf’s AC_SYS_POSIX_TERMIOS
does not look there (even though the configure.ac
of a program I am looking at does use AC_CHECK_HEADERS([ … sys/termios.h … termios.h …])
, I was wondering:
Is there any system in existence which has <sys/termios.h>
with the usual suspects (tcgetattr
, tcsetattr
, cfgetospeed
and related constants) but not <termios.h>
?
Another piece of software I’m looking at only tries <termios.h
> (both fall back to termio, one even to sgtty…), and I’m now trying to figure out whether I should patch one to also look at <sys/termios.h>
(and probably the autoconf macro, too) or patch the other to not look there because it might be pointless.
c portability autoconf termios
4
POSIX specifies<termios.h>
, so any OS claiming conformance should have that.
– Barmar
Nov 8 at 3:03
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
1
I used the file search at TUHS. SysIII seems to be the earliest incarnation of<termio.h>
(note the lack of an S), which<termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used withioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using<sgtty.h>
, notably on BSD systems before<sys/termios.h>
. My guess is that<sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as<termios.h>
– Chrono Kitsune
Nov 15 at 5:44
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I am currently pondering the presence of <sys/termios.h>
on many systems, most of which have a symlink between it and <termios.h>
, musl libc’s being a considerable exception: its <sys/termios.h>
warns you that it’s wrong and to use <termios.h>
instead.
On the BSDs, the actual file is in sys/
and the symlink in /usr/include
, so one might have been historically excused for using this… but, giving that GNU autoconf’s AC_SYS_POSIX_TERMIOS
does not look there (even though the configure.ac
of a program I am looking at does use AC_CHECK_HEADERS([ … sys/termios.h … termios.h …])
, I was wondering:
Is there any system in existence which has <sys/termios.h>
with the usual suspects (tcgetattr
, tcsetattr
, cfgetospeed
and related constants) but not <termios.h>
?
Another piece of software I’m looking at only tries <termios.h
> (both fall back to termio, one even to sgtty…), and I’m now trying to figure out whether I should patch one to also look at <sys/termios.h>
(and probably the autoconf macro, too) or patch the other to not look there because it might be pointless.
c portability autoconf termios
I am currently pondering the presence of <sys/termios.h>
on many systems, most of which have a symlink between it and <termios.h>
, musl libc’s being a considerable exception: its <sys/termios.h>
warns you that it’s wrong and to use <termios.h>
instead.
On the BSDs, the actual file is in sys/
and the symlink in /usr/include
, so one might have been historically excused for using this… but, giving that GNU autoconf’s AC_SYS_POSIX_TERMIOS
does not look there (even though the configure.ac
of a program I am looking at does use AC_CHECK_HEADERS([ … sys/termios.h … termios.h …])
, I was wondering:
Is there any system in existence which has <sys/termios.h>
with the usual suspects (tcgetattr
, tcsetattr
, cfgetospeed
and related constants) but not <termios.h>
?
Another piece of software I’m looking at only tries <termios.h
> (both fall back to termio, one even to sgtty…), and I’m now trying to figure out whether I should patch one to also look at <sys/termios.h>
(and probably the autoconf macro, too) or patch the other to not look there because it might be pointless.
c portability autoconf termios
c portability autoconf termios
edited Nov 8 at 7:03
JJJ
29k147591
29k147591
asked Nov 8 at 2:59
mirabilos
3,4232855
3,4232855
4
POSIX specifies<termios.h>
, so any OS claiming conformance should have that.
– Barmar
Nov 8 at 3:03
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
1
I used the file search at TUHS. SysIII seems to be the earliest incarnation of<termio.h>
(note the lack of an S), which<termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used withioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using<sgtty.h>
, notably on BSD systems before<sys/termios.h>
. My guess is that<sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as<termios.h>
– Chrono Kitsune
Nov 15 at 5:44
add a comment |
4
POSIX specifies<termios.h>
, so any OS claiming conformance should have that.
– Barmar
Nov 8 at 3:03
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
1
I used the file search at TUHS. SysIII seems to be the earliest incarnation of<termio.h>
(note the lack of an S), which<termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used withioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using<sgtty.h>
, notably on BSD systems before<sys/termios.h>
. My guess is that<sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as<termios.h>
– Chrono Kitsune
Nov 15 at 5:44
4
4
POSIX specifies
<termios.h>
, so any OS claiming conformance should have that.– Barmar
Nov 8 at 3:03
POSIX specifies
<termios.h>
, so any OS claiming conformance should have that.– Barmar
Nov 8 at 3:03
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
1
1
I used the file search at TUHS. SysIII seems to be the earliest incarnation of
<termio.h>
(note the lack of an S), which <termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used with ioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using <sgtty.h>
, notably on BSD systems before <sys/termios.h>
. My guess is that <sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as <termios.h>
– Chrono Kitsune
Nov 15 at 5:44
I used the file search at TUHS. SysIII seems to be the earliest incarnation of
<termio.h>
(note the lack of an S), which <termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used with ioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using <sgtty.h>
, notably on BSD systems before <sys/termios.h>
. My guess is that <sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as <termios.h>
– Chrono Kitsune
Nov 15 at 5:44
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53200928%2fare-there-oses-which-have-sys-termios-h-but-not-termios-h%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
4
POSIX specifies
<termios.h>
, so any OS claiming conformance should have that.– Barmar
Nov 8 at 3:03
Sure it does, but I was asking about portability, not about POSIX. This means especially to run on systems that predate or don’t implement POSIX.
– mirabilos
Nov 8 at 11:52
Much of POSIX simply made existing practice among Unix variants official. And where there was no concensus (i.e. hard split between AT&T and BSD), it frequently copped out and said that either method was conforming.
– Barmar
Nov 8 at 16:08
Sure, but this is deliberately an archæology question, for portability to ancient weird systems someone may have around at VCFe or in some emulator. I know enough people dealing in those, but not experts like the autoconf people (e.g. @BrunoHaible) who know whether there was a system in existence that did so-and-so.
– mirabilos
Nov 8 at 20:29
1
I used the file search at TUHS. SysIII seems to be the earliest incarnation of
<termio.h>
(note the lack of an S), which<termios.h>
was heavily based upon, though it lacked "the usual suspects" and was apparently used withioctl
instead. I dug around for older TTY-related files/functions the site had (other than termcap), and it seems that you'd be looking at using<sgtty.h>
, notably on BSD systems before<sys/termios.h>
. My guess is that<sys/termios.h>
is/was a BSD thing; other systems POSIX-correctly have it installed as<termios.h>
– Chrono Kitsune
Nov 15 at 5:44