]> git.pond.sub.org Git - empserver/blobdiff - m4/my_terminfo.m4
m4: Refresh macros from autoconf-archive commit fd1d25c148
[empserver] / m4 / my_terminfo.m4
index 7fb651361079d82430c34092c89a363e836e9659..f4d33bdfef0335d2782572ad99eebc5c2887ce5a 100644 (file)
@@ -2,8 +2,8 @@ AC_DEFUN([MY_CURSES_TERMINFO],
 [
        AC_SEARCH_LIBS([setupterm], [termlib termcap curses ncurses],
                [have_terminfo=yes], [have_terminfo=no])
-       AC_CHECK_HEADER([curses.h], , [have_terminfo=no])
-       AC_CHECK_HEADER([term.h], , [have_terminfo=no])
+       AC_CHECK_HEADERS([curses.h term.h], [], [have_terminfo=no],
+       [[#include <curses.h>]])
        if test "$have_terminfo" = yes
        then AC_DEFINE([HAVE_CURSES_TERMINFO], 1,
                [Define if you have the curses interface to terminfo])
@@ -14,11 +14,11 @@ AC_DEFUN([MY_WITH_TERMINFO],
 [
        AC_ARG_WITH([terminfo],
                AS_HELP_STRING([--with-terminfo],
-                       [use terminfo for highlighting (default check)]))
+                       [use terminfo for highlighting @<:@default check@:>@]))
        if test "x$with_terminfo" != xno; then
                MY_CURSES_TERMINFO
                if test "$have_terminfo$with_terminfo" = noyes
-               then AC_MSG_FAILURE([Can't satisfy --with-terminfo])
+               then AC_MSG_FAILURE([--with-terminfo was given, but test for terminfo failed])
                fi
                with_terminfo="$have_terminfo"
        fi