From bfb1dc40f14b0a3d7ffd1a2dfda0fadca35c611a Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Sat, 3 Mar 2001 05:17:36 +0000 Subject: [PATCH] Don't even try to use . If we're using ncurses, don't override the definitions in , but do supply definitions for things not defined there. Add abstract speed_t type, which is defined in recent files. --- v7/src/microcode/acconfig.h | 5 ++++- v7/src/microcode/configure.in | 21 +++++++++++++++++++-- v7/src/microcode/tterm.c | 30 +++++++++++++----------------- 3 files changed, 36 insertions(+), 20 deletions(-) diff --git a/v7/src/microcode/acconfig.h b/v7/src/microcode/acconfig.h index 143ee6081..ae6e4f639 100644 --- a/v7/src/microcode/acconfig.h +++ b/v7/src/microcode/acconfig.h @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: acconfig.h,v 11.3 2001/03/02 18:03:06 cph Exp $ +$Id: acconfig.h,v 11.4 2001/03/03 05:17:29 cph Exp $ Copyright (c) 2000-2001 Massachusetts Institute of Technology @@ -41,6 +41,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. /* Define to `unsigned char' if doesn't define. */ #undef cc_t +/* Define to `short' if doesn't define. */ +#undef speed_t + /* Define if `struct ltchars' is defined in . */ #undef HAVE_STRUCT_LTCHARS diff --git a/v7/src/microcode/configure.in b/v7/src/microcode/configure.in index d04497d2a..882d78b9b 100644 --- a/v7/src/microcode/configure.in +++ b/v7/src/microcode/configure.in @@ -16,7 +16,7 @@ dnl You should have received a copy of the GNU General Public License dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -AC_REVISION([$Id: configure.in,v 11.6 2001/03/02 18:02:58 cph Exp $]) +AC_REVISION([$Id: configure.in,v 11.7 2001/03/03 05:17:32 cph Exp $]) AC_INIT(boot.c) AC_CONFIG_HEADER(config.h) @@ -195,7 +195,7 @@ AC_HEADER_TIME AC_CHECK_HEADERS(bsdtty.h fcntl.h limits.h malloc.h sgtty.h stropts.h time.h) AC_CHECK_HEADERS(sys/file.h sys/ioctl.h sys/mount.h sys/param.h sys/poll.h) AC_CHECK_HEADERS(sys/ptyio.h sys/socket.h sys/time.h sys/un.h sys/vfs.h) -AC_CHECK_HEADERS(termcap.h termio.h termios.h unistd.h utime.h) +AC_CHECK_HEADERS(termio.h termios.h unistd.h utime.h) AC_CHECK_HEADERS(openssl/blowfish.h openssl/md5.h blowfish.h md5.h) dnl Checks for typedefs @@ -277,6 +277,23 @@ if test "${scheme_cv_type_cc_t}" = "no"; then AC_DEFINE(cc_t, unsigned char) fi +AC_MSG_CHECKING([for speed_t]) +AC_TRY_COMPILE([ +#ifdef HAVE_TERMIOS_H +# include +#else +# ifdef HAVE_TERMIO_H +# include +# endif +#endif], + [speed_t x;], + [scheme_cv_type_speed_t=yes], + [scheme_cv_type_speed_t=no]) +AC_MSG_RESULT(${scheme_cv_type_speed_t}) +if test "${scheme_cv_type_speed_t}" = "no"; then + AC_DEFINE(speed_t, short) +fi + dnl Checks for structures. AC_STRUCT_TM AC_STRUCT_TIMEZONE diff --git a/v7/src/microcode/tterm.c b/v7/src/microcode/tterm.c index d760af11b..ec549ea20 100644 --- a/v7/src/microcode/tterm.c +++ b/v7/src/microcode/tterm.c @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: tterm.c,v 1.11 2001/03/03 02:01:21 cph Exp $ +$Id: tterm.c,v 1.12 2001/03/03 05:17:36 cph Exp $ Copyright (c) 1990-2001 Massachusetts Institute of Technology @@ -28,25 +28,21 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #ifdef HAVE_LIBNCURSES # include # include - extern char * EXFUN (tparam, (CONST char *, PTR, int, ...)); #else -# ifdef HAVE_TERMCAP_H -# include -# else - extern int EXFUN (tgetent, (char *, CONST char *)); - extern int EXFUN (tgetnum, (CONST char *)); - extern int EXFUN (tgetflag, (CONST char *)); - extern char * EXFUN (tgetstr, (CONST char *, char **)); - extern char * EXFUN (tgoto, (CONST char *, int, int)); - extern int EXFUN (tputs, (CONST char *, int, void (*) (int))); - extern char * EXFUN (tparam, (CONST char *, PTR, int, ...)); - extern char * BC; - extern char * UP; - extern char PC; - extern short ospeed; -# endif + extern int EXFUN (tgetent, (char *, CONST char *)); + extern int EXFUN (tgetnum, (CONST char *)); + extern int EXFUN (tgetflag, (CONST char *)); + extern char * EXFUN (tgetstr, (CONST char *, char **)); + extern char * EXFUN (tgoto, (CONST char *, int, int)); + extern int EXFUN (tputs, (CONST char *, int, void (*) (int))); #endif +extern char * EXFUN (tparam, (CONST char *, PTR, int, ...)); +extern char * BC; +extern char * UP; +extern char PC; +extern speed_t ospeed; + #ifndef TERMCAP_BUFFER_SIZE #define TERMCAP_BUFFER_SIZE 2048 #endif -- 2.25.1