Skip to content
Permalink
Browse files

Add support for GNU/Hurd to GRASS plugin qtermwidget/kpty.cpp.

The GNU/Hurd porting guidelines document the following:
"
 Missing termio.h

 Change it to use termios.h (check for it properly with autoconf
 HAVE_TERMIOS_H or the __GLIBC__ macro)

 Also, change calls to ioctl(fd, TCGETS, ...) and ioctl(fd, TCSETS, ...)
 with tcgetattr(fd, ...) and tcsetattr(fd, ...).
"
https://www.gnu.org/software/hurd/hurd/porting/guidelines.html#Missing_termio_h_tt_
  • Loading branch information
sebastic committed May 14, 2016
1 parent 45e7da1 commit 666050c57cf825ce41fd485a25dae9666dedd923
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/plugins/grass/qtermwidget/kpty.cpp
@@ -120,7 +120,7 @@ extern "C" {
#if defined (__FreeBSD__) || defined(__FreeBSD_kernel__) || defined (__NetBSD__) || defined (__OpenBSD__) || defined (__bsdi__) || defined(__APPLE__) || defined (__DragonFly__)
# define _tcgetattr(fd, ttmode) ioctl(fd, TIOCGETA, (char *)ttmode)
#else
# if defined(_HPUX_SOURCE) || defined(__Lynx__) || defined (__CYGWIN__)
# if defined(_HPUX_SOURCE) || defined(__Lynx__) || defined (__CYGWIN__) || defined(__GNU__)
# define _tcgetattr(fd, ttmode) tcgetattr(fd, ttmode)
# else
# define _tcgetattr(fd, ttmode) ioctl(fd, TCGETS, (char *)ttmode)
@@ -130,7 +130,7 @@ extern "C" {
#if defined (__FreeBSD__) || defined(__FreeBSD_kernel__) || defined (__NetBSD__) || defined (__OpenBSD__) || defined (__bsdi__) || defined(__APPLE__) || defined (__DragonFly__)
# define _tcsetattr(fd, ttmode) ioctl(fd, TIOCSETA, (char *)ttmode)
#else
# if defined(_HPUX_SOURCE) || defined(__CYGWIN__)
# if defined(_HPUX_SOURCE) || defined(__CYGWIN__) || defined(__GNU__)
# define _tcsetattr(fd, ttmode) tcsetattr(fd, TCSANOW, ttmode)
# else
# define _tcsetattr(fd, ttmode) ioctl(fd, TCSETS, (char *)ttmode)

0 comments on commit 666050c

Please sign in to comment.
You can’t perform that action at this time.