X-Git-Url: https://git.wh0rd.org/?p=dump.git;a=blobdiff_plain;f=configure.in;h=dcb6bfb7296c4de2062594f5add1bd55bc82f677;hp=1bc05a6b53dca39f7372874435a80a1fc2133304;hb=6169d8400ef19c54b1a5ccc0fec865ade5344f7d;hpb=882090d1f96018bce58594e1fff5e06340bbc412 diff --git a/configure.in b/configure.in index 1bc05a6..dcb6bfb 100644 --- a/configure.in +++ b/configure.in @@ -100,7 +100,7 @@ if test "$enableval" = "no" then READLINE="" else - READLINE="-lreadline" + READLINE="-lreadline -ltermcap" AC_DEFINE(HAVE_READLINE) fi , @@ -260,13 +260,23 @@ if test "$ext2fs_h" = no -o "$ext2fs_lib" = no; then AC_MSG_ERROR(You need to install the Ext2fs libraries from the E2fsprogs distribution first - hint: make install-libs) fi +dnl +dnl Check for termcap libraries +dnl +AC_CHECK_LIB(termcap, tgetent, [termcap_lib=yes], [termcap_lib=no]) +if test "$termcap_lib" = no; then + if test "$READLINE" = "-lreadline -ltermcap"; then + AC_MSG_ERROR(You need to install the GNU termcap libraries first) + fi +fi + dnl dnl Check for readline headers and libraries dnl AC_CHECK_HEADER(readline/readline.h, [readline_h=yes], [readline_h=no]) -AC_CHECK_LIB(readline, readline, [readline_lib=yes], [readline_lib=no]) +AC_CHECK_LIB(readline, readline, [readline_lib=yes], [readline_lib=no], "-ltermcap") if test "$readline_h" = no -o "$readline_lib" = no; then - if test "$READLINE" = "-lreadline"; then + if test "$READLINE" = "-lreadline -ltermcap"; then AC_MSG_ERROR(You need to install the GNU readline libraries first) fi fi