summaryrefslogtreecommitdiff
path: root/source3/configure.in
diff options
context:
space:
mode:
authorMartin Pool <mbp@samba.org>2001-11-19 04:18:45 +0000
committerMartin Pool <mbp@samba.org>2001-11-19 04:18:45 +0000
commitb99209cce4a91de279bb62dbc4246845bf0e755d (patch)
treea895f0d26821550ab7f0b7fa65a48ed8bb84c316 /source3/configure.in
parent40b8b058d2b4a3c41d0bc1248c9924569118dc12 (diff)
downloadsamba-b99209cce4a91de279bb62dbc4246845bf0e755d.tar.gz
samba-b99209cce4a91de279bb62dbc4246845bf0e755d.tar.bz2
samba-b99209cce4a91de279bb62dbc4246845bf0e755d.zip
Detect libreadline>=4.0, and set HAVE_NEW_LIBREADLINE. At the moment
this is only to get the cast right, but it might help with other parts of the API that changed later. (This used to be commit b792c9317ab62fe407de34ed811cc883a7652cc4)
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in9
1 files changed, 9 insertions, 0 deletions
diff --git a/source3/configure.in b/source3/configure.in
index aacad250f8..506a34d941 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -483,6 +483,15 @@ AC_ARG_WITH(readline,
AC_SUBST(TERMLIBS)
AC_SUBST(TERMLDFLAGS)
+# The readline API changed slightly from readline3 to readline4, so
+# code will generate warnings on one of them unless we have a few
+# special cases.
+AC_CHECK_LIB(readline, rl_completion_matches,
+ [AC_DEFINE(HAVE_NEW_LIBREADLINE, 1,
+ [Do we have rl_completion_matches?])],
+ [],
+ [$TERMLIBS])
+
# The following test taken from the cvs sources
# If we can't find connect, try looking in -lsocket, -lnsl, and -linet.
# The Irix 5 libc.so has connect and gethostbyname, but Irix 5 also has