+2013-01-02 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Check for ncursesw5-config and base $CPPFLAGS based on it.
+
2013-01-09 Fabian Groffen <grobian@Savannah>
* configure.ac, src/nano.h: Make search for ncursesw more generalized.
if test x$enable_utf8 != xno; then
AC_CHECK_HEADERS(ncursesw/ncurses.h)
- AC_CHECK_LIB(ncursesw, get_wch, [CURSES_LIB="-lncursesw" CURSES_LIB_NAME=ncursesw CURSES_LIB_WIDE=yes])
+ AC_CHECK_TOOL(NCURSESW_CONFIG, ncursesw5-config, no)
+ if test "x$NCURSESW_CONFIG" != xno; then
+ CURSES_LIB=`$NCURSESW_CONFIG --libs`
+ CPPFLAGS="`$NCURSESW_CONFIG --cflags` $CPPFLAGS"
+ CURSES_LIB_NAME=ncursesw
+ CURSES_LIB_WIDE=yes
+ else
+ AC_CHECK_LIB(ncursesw, get_wch, [CURSES_LIB="-lncursesw" CURSES_LIB_NAME=ncursesw CURSES_LIB_WIDE=yes])
+ fi
fi
if eval "test x$CURSES_LIB_NAME = x"; then