Skip to content

Commit 0b87bb0

Browse files
committed
Fix libreadline summary output
AC_CHECK_LIB([readline], [readline]) without an ACTION-IF-FOUND results in the definition of the HAVE_LIBREADLINE (all caps) variable, not have_readline.
1 parent bff4899 commit 0b87bb0

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/configure.ac

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,11 @@ AC_CHECK_LIB([ws2_32], [WSAStartup])
116116

117117
AC_CHECK_LIB([termcap], [tputs])
118118
AC_CHECK_LIB([ncurses], [tputs])
119-
AC_CHECK_LIB([readline], [readline])
119+
AC_CHECK_LIB([readline], [readline], [dnl
120+
AC_DEFINE([HAVE_LIBREADLINE], [1],
121+
[Whether we have libreadline with the readline function])
122+
have_libreadline=yes
123+
])
120124
AH_TEMPLATE([HAVE_LIBELF],
121125
[Define if ELF support is enabled via libelf])
122126
AC_CHECK_LIB([elf], [elf_getshdrstrndx], [have_libelf=yes])
@@ -674,7 +678,7 @@ else
674678
echo "DON'T HAVE libhidapi"
675679
fi
676680

677-
if test "x$have_readline" = xyes; then
681+
if test "x$have_libreadline" = xyes; then
678682
echo "DO HAVE libreadline"
679683
else
680684
echo "DON'T HAVE libreadline"

0 commit comments

Comments
 (0)