From c7dcf042487e4651b695a140795044633e08e066 Mon Sep 17 00:00:00 2001 From: Sergey 'Jin' Bostandzhyan Date: Mon, 26 Aug 2013 14:05:14 +0300 Subject: [PATCH] Fix configure for Free BSD * seems that /usr/local is not in the default ld path on FreeBSD, so add it manually * search for wget_wch instead of get_wch, on FreeBSD get_wch seems to be available as a macro, which does not automatically mean that wide char support is really available --- configure.ac | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/configure.ac b/configure.ac index 5fd25ef..8de91a0 100644 --- a/configure.ac +++ b/configure.ac @@ -82,9 +82,13 @@ case $host_os in *mingw*) WIN32="yes" ;; + *freebsd*) + LDFLAGS="$LDFLAGS -L/usr/local/lib" + CFLAGS="$CFLAGS -I/usr/local/include" + CPPFLAGS="$CPPFLAGS -I/usr/local/include" + ;; esac - # Checks for programs. AC_PROG_CC AM_PROG_CC_C_O @@ -235,13 +239,13 @@ if test "x$NCURSES_FOUND" = "xno"; then ] ) else - AC_CHECK_LIB([ncursesw], [get_wch], + AC_CHECK_LIB([ncursesw], [wget_wch], [ NCURSES_WIDECHAR_SUPPORT="yes" ], [ - unset ac_cv_lib_ncursesw_get_wch - AC_CHECK_LIB([ncursesw], [get_wch], + unset ac_cv_lib_ncursesw_wget_wch + AC_CHECK_LIB([ncursesw], [wget_wch], [ NCURSES_WIDECHAR_SUPPORT="yes" ], @@ -250,7 +254,7 @@ if test "x$NCURSES_FOUND" = "xno"; then AC_CHECK_LIB([ncurses], [clear], [], [ - unset ac_cv_lib_ncursesw_get_wch + unset ac_cv_lib_ncurses_clear AC_CHECK_LIB([ncurses], [clear], [], [