New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Solaris should support constants like termios' FIONREAD #76841
Comments
Solaris supports termios constants like FIONREAD with an appropiate "#include" in the C code. The main issue is that some names conflicts between System V and BSD personalities. I could evaluate the situation and do a patch proposal for Python 3.7. We are still a week away of 3.7RC1 and this patch would affect only Solaris/derivatives. |
Solaris has two personalities: System V and BSD. This is not usually an issue but sometimes some constants have a different value in a mode or the other. By default, when including <sys/ioctl.h> Solaris is in System V mode. We can force BSD mode defining symbol "BSD_COMP". This greatly expand the names available but, unfortunately, some values change. The comment in <sys/ioctl.h> is quite clear: """
""" Using "gcc -dM -E" we can observe defined symbols. Ambiguous values when defininf "BSD_COMP" are: BS0, BS1, CR0, CR1, CR2, CR3, ECHO, FF0, FF1, FLUSHO, NL0, NL1, NOFLSH, PENDIN, TAB0, TAB1, TAB2, TOSTOP, XTABS. Sounds quite important, actually. Since I am no aiming to perfection, I would be satisfied making quite a few new symbols available, not all of them. A simple approach would be to include <sys/filio.h> and <sys/sockio.h>. In those header files there are only constants, not functions or data structures. Just including those headers we get these new symbols (none overlapping other): _FIO_COMPRESSED Not all those symbols are going to be exported in Python. |
After doing this change, I see FIVE new symbols in Python's termios: """ Good enough for now and me. |
With this change, a SmarOS native zone exports 206 symbols in Python termios. Before it export 201. By comparison, a Linux Ubuntu 16.04 Python provides 244 symbols. Some references for the future: |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: