dnl Process this file with autoconf to produce a configure script.
AC_PREREQ(2.57)
-AC_INIT([gnushogi],[1.3.2],[mvanier@cs.caltech.edu])
+AC_INIT([gnushogi],[1.4.0+],[https://savannah.gnu.org/bugs/?group=gnushogi])
AC_CONFIG_SRCDIR([version.h])
AC_CONFIG_HEADER(config.h)
echo
AC_PATH_XTRA
+#
+# Check for ncurses.
+#
+
+AC_ARG_WITH([curses],
+ [AS_HELP_STRING([--with-curses],
+ [enable curses UI])],
+ [],
+ [with_curses=check])
+
+LIBCURSES=
+AS_IF([test "x$with_curses" != xno],
+ [AC_CHECK_LIB([curses], [clrtoeol],
+ [AC_SUBST([LIBCURSES], ["-lcurses"])
+ AC_DEFINE([HAVE_LIBCURSES], [1],
+ [Define if you have lib])
+ ],
+ [AC_MSG_FAILURE(
+ [--with-curses was given, but test for curses failed])],
+ [-ltermcap])])
#
# Check for other libraries.
#
-AC_CHECK_LIB(curses, clrtoeol)
AC_CHECK_LIB(m, pow)
dnl Replace `main' with a function in -ltermcap:
AC_CHECK_LIB(termcap, tgoto)
AC_ARG_WITH(second-shogi-program,
[ --with-second-shogi-program=PROGNAME
- Use PROGNAME as the second shogi program in xshogi(default: gnushogi)],
+ Use PROGNAME as the second shogi program in xshogi (default: gnushogi)],
SECOND_SHOGI_PROGRAM=$withval)
AC_ARG_WITH(first-host,