From: Chris Hanson Date: Fri, 2 Mar 2001 18:03:17 +0000 (+0000) Subject: Add extra compile-time flag to specify whether libncurses defines the X-Git-Tag: 20090517-FFI~2940 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=7965a258b993c2333a41c80ee3ba15fb71a73896;p=mit-scheme.git Add extra compile-time flag to specify whether libncurses defines the `tparam' procedure. --- diff --git a/v7/src/microcode/acconfig.h b/v7/src/microcode/acconfig.h index 4102f5cb0..143ee6081 100644 --- a/v7/src/microcode/acconfig.h +++ b/v7/src/microcode/acconfig.h @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: acconfig.h,v 11.2 2001/03/01 04:25:48 cph Exp $ +$Id: acconfig.h,v 11.3 2001/03/02 18:03:06 cph Exp $ Copyright (c) 2000-2001 Massachusetts Institute of Technology @@ -92,6 +92,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. /* Define if ncurses library is present. */ #undef HAVE_LIBNCURSES +/* Define if ncurses library defines `tparam'. */ +#undef LIBNCURSES_DEFINES_TPARAM + /* Define if termcap library is present. */ #undef HAVE_LIBTERMCAP diff --git a/v7/src/microcode/configure.in b/v7/src/microcode/configure.in index d2a1823ab..d04497d2a 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.5 2001/03/01 04:25:51 cph Exp $]) +AC_REVISION([$Id: configure.in,v 11.6 2001/03/02 18:02:58 cph Exp $]) AC_INIT(boot.c) AC_CONFIG_HEADER(config.h) @@ -80,8 +80,8 @@ AC_CHECK_LIB(ncurses, tparm, [scheme_cv_lib_ncurses=no]) if test "${scheme_cv_lib_ncurses}" = "yes"; then AC_CHECK_LIB(ncurses, tparam, - [scheme_cv_lib_ncurses_has_tparam=yes], - [scheme_cv_lib_ncurses_has_tparam=no]) + [scheme_cv_lib_ncurses_defines_tparam=yes], + [scheme_cv_lib_ncurses_defines_tparam=no]) fi AC_CHECK_LIB(curses, tparm, [scheme_cv_lib_curses=yes], @@ -164,7 +164,9 @@ fi if test "${scheme_cv_lib_ncurses}" = "yes"; then AC_DEFINE(HAVE_LIBNCURSES) QUASI_STATIC_LIBS="${QUASI_STATIC_LIBS} -lncurses" - if test "${scheme_cv_lib_ncurses_has_tparam}" = "no"; then + if test "${scheme_cv_lib_ncurses_defines_tparam}" = "yes"; then + AC_DEFINE(LIBNCURSES_DEFINES_TPARAM) + else OPTIONAL_BASES="${OPTIONAL_BASES} terminfo" fi elif test "${scheme_cv_lib_curses}" = "yes"; then diff --git a/v7/src/microcode/tterm.c b/v7/src/microcode/tterm.c index b6a30b9ee..1dff8e185 100644 --- a/v7/src/microcode/tterm.c +++ b/v7/src/microcode/tterm.c @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: tterm.c,v 1.9 2001/03/01 04:25:29 cph Exp $ +$Id: tterm.c,v 1.10 2001/03/02 18:03:17 cph Exp $ Copyright (c) 1990-2001 Massachusetts Institute of Technology @@ -40,7 +40,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. extern short ospeed; #endif -extern char * EXFUN (tparam, (char *, char*, int, int, ...)); +#ifndef LIBNCURSES_DEFINES_TPARAM + extern char * EXFUN (tparam, (char *, char*, int, int, ...)); +#endif #ifndef TERMCAP_BUFFER_SIZE #define TERMCAP_BUFFER_SIZE 2048