Index: configure.ac ================================================================== --- configure.ac +++ configure.ac @@ -20,14 +20,20 @@ AC_SEARCH_LIBS(getch, ncurses curses tinfo,, [ AC_MSG_ERROR([Unable to determine how to link to curses]) ]) AC_SEARCH_LIBS(curses_version, ncurses curses tinfo) +AC_SEARCH_LIBS(curs_set, ncurses curses tinfo) +AC_SEARCH_LIBS(set_term, ncurses curses tinfo) +AC_SEARCH_LIBS(beep, ncurses curses tinfo) +AC_SEARCH_LIBS(keypad, ncurses curses tinfo) + +AC_CHECK_FUNCS(curs_set set_term beep keypad) dnl Look for appropriate headers AC_HEADER_STDC -AC_CHECK_HEADERS(ctype.h curses.h errno.h fcntl.h limits.h math.h ncurses.h pwd.h signal.h stddef.h stdio.h stdlib.h string.h sys/file.h sys/select.h sys/stat.h sys/time.h sys/times.h sys/types.h tcl.h unistd.h) +AC_CHECK_HEADERS(ctype.h curses.h curses/curses.h curses/ncurses.h ncurses/ncurses.h errno.h fcntl.h limits.h math.h ncurses.h pwd.h signal.h stddef.h stdio.h stdlib.h string.h sys/file.h sys/select.h sys/stat.h sys/time.h sys/times.h sys/types.h tcl.h unistd.h) dnl Determine what type of targets to build TARGETS="libctk.${SHOBJEXT}" CFLAGS="${CFLAGS} ${SHOBJFLAGS}" AC_SUBST(TARGETS) Index: ctkDisplay.c ================================================================== --- ctkDisplay.c +++ ctkDisplay.c @@ -12,16 +12,19 @@ */ #include "tkPort.h" #include "tkInt.h" #include -#ifdef USE_NCURSES_H -# include -#else -# include +#ifdef HAVE_CURSES_H +# include +#elif defined(HAVE_CURSES_CURSES_H) +# include +#elif defined(HAVE_CURSES_NCURSES_H) +# include +#elif defined(HAVE_NCURSES_NCURSES_H) +# include #endif - #ifdef CLK_TCK # define MS_PER_CLOCK (1000.0/CLK_TCK) #elif defined HZ # define MS_PER_CLOCK (1000.0/HZ) #else Index: tkBind.c ================================================================== --- tkBind.c +++ tkBind.c @@ -14,14 +14,18 @@ * @(#) $Id: ctk.shar,v 1.50 1996/01/15 14:47:16 andrewm Exp andrewm $ */ #include "tkPort.h" #include "tkInt.h" -#ifdef USE_NCURSES_H -# include -#else -# include +#ifdef HAVE_CURSES_H +# include +#elif defined(HAVE_CURSES_CURSES_H) +# include +#elif defined(HAVE_CURSES_NCURSES_H) +# include +#elif defined(HAVE_NCURSES_NCURSES_H) +# include #endif /* * The structure below represents a binding table. A binding table * represents a domain in which event bindings may occur. It includes