Date: Mon, 26 Mar 2007 23:19:40 +0200 (CEST) From: Ed Schouten <ed@fxq.nl> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/110884: games/tads: use <termios.h> instead of <sgtty.h> Message-ID: <20070326211940.9A9301CC79@palm.hoeg.nl> Resent-Message-ID: <200703262120.l2QLK3Sc044364@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 110884 >Category: ports >Synopsis: games/tads: use <termios.h> instead of <sgtty.h> >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Mar 26 21:20:02 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Ed Schouten >Release: FreeBSD 6.2-STABLE i386 >Organization: >Environment: System: FreeBSD palm.hoeg.nl 6.2-STABLE FreeBSD 6.2-STABLE #0: Sun Feb 11 22:32:09 CET 2007 root@palm.hoeg.nl:/usr/obj/usr/src/sys/PALM i386 >Description: One of the last remaining ports on my list that isn't hard to port to <termios.h>, is TADS. Using <termios.h> instead of <sgtty.h> will make the application work on kernels that aren't compiled with COMPAT_43/COMPAT_43TTY. >How-To-Repeat: >Fix: Place the following patch in the `files/' directory. The unportable `t.c_cflag & CBAUD' line has been replaced with cfgetospeed(). This looks like the right thing to do, because on Linux, cfgetospeed() is a macro to exactly the same thing. --- osunixt.c Wed Dec 15 03:06:26 2004 +++ osunixt.c Mon Mar 26 23:07:34 2007 @@ -960,7 +960,7 @@ t.c_cc[VMIN] = 1; t.c_cc[VTIME] = 0; #if !defined(SGI_IRIX) - t.c_oflag &= (~XTABS); + t.c_oflag &= (~OXTABS); #else t.c_oflag &= (~TAB3); #endif @@ -984,7 +984,7 @@ #ifdef USE_SGTTY ospeed = t.sg_ospeed; #else - ospeed = t.c_cflag & CBAUD; + ospeed = cfgetospeed(&t); #endif if (ospeed == 0) ospeed = 11; --- osunixt.h Tue Feb 17 03:20:41 2004 +++ osunixt.h Mon Mar 26 23:07:34 2007 @@ -84,7 +84,7 @@ * Define the following to use sgtty.h instead of termios or direct * ioctl hacking. */ -#if defined(NEXT) || defined(IBM_RT) || defined(FREEBSD_386) || defined(IBM_AIX) || defined(NETBSD) || defined(OPENBSD) || defined(DARWIN) +#if defined(NEXT) || defined(IBM_RT) || defined(IBM_AIX) || defined(NETBSD) || defined(OPENBSD) || defined(DARWIN) #define USE_IOCTL_INSTEAD_OF_TERMIOS #define USE_SGTTY #endif >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070326211940.9A9301CC79>