Link with the tinfo library
On some systems we have to explicitly link with libtinfo.
pkg-config cannot be used on every system with ncurses,
see discussion in https://bugs.gentoo.org/show_bug.cgi?id=457530#c18
For now we'll use the same fix as Mutt:
https://dev.mutt.org/hg/mutt/rev/c84aa0d62ce3
Thanks to Wolfram Schlich for the report and troubleshooting!
--- a/mcabber/configure.ac Sun Jun 05 20:06:46 2016 +0200
+++ b/mcabber/configure.ac Mon Sep 12 22:39:04 2016 +0200
@@ -99,6 +99,9 @@
done
AC_CHECK_LIB($cf_ncurses, initscr,
[LIBS="$LIBS -l$cf_ncurses"
+
+ AC_CHECK_LIB(tinfo, tgetent, [LIBS="$LIBS -ltinfo"])
+
if test "$cf_ncurses" = ncursesw; then
AC_CHECK_HEADERS([ncursesw/ncurses.h ncursesw/panel.h],,
[AC_CHECK_HEADERS([ncurses.h panel.h],,
@@ -161,7 +164,7 @@
[loudmouth is now using a new digest]
),
[]
- )
+ )
# Check for lm_ssl_set_cipher_list in loudmouth
AC_CHECK_LIB(loudmouth-1, lm_ssl_set_cipher_list,