summaryrefslogtreecommitdiff
path: root/m4/ax_lib_readline.m4
diff options
context:
space:
mode:
authorPeter Kokot <peterkokot@gmail.com>2018-07-24 01:44:43 +0200
committerPeter Kokot <peterkokot@gmail.com>2018-07-24 01:44:43 +0200
commitb45fd8dd0a8dabba7e8cba99e8c13e84d93ba858 (patch)
tree51f5c3c30d449b30c958aca39ccaa00f45b2bbf8 /m4/ax_lib_readline.m4
parent7f44296a6683be232d6f945f03cecf50ce1ca641 (diff)
downloadautoconf-archive-b45fd8dd0a8dabba7e8cba99e8c13e84d93ba858.tar.gz
Replace obsolete AC_TRY_LINK_FUNCTION macros
Autoconf 2.50 introduced new macros in favor of the AC_TRY_FOO. Since Autoconf 2.55 the AC_TRY_LINK_FUNC macro has been additionally marked as obsolete and suggested to be replaced with AC_LINK_IFELSE and AC_LANG_CALL. Refs: - http://git.savannah.gnu.org/cgit/autoconf.git/tree/NEWS - https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Obsolete-Macros.html
Diffstat (limited to 'm4/ax_lib_readline.m4')
-rw-r--r--m4/ax_lib_readline.m46
1 files changed, 3 insertions, 3 deletions
diff --git a/m4/ax_lib_readline.m4 b/m4/ax_lib_readline.m4
index 8b9eef5..0d0822b 100644
--- a/m4/ax_lib_readline.m4
+++ b/m4/ax_lib_readline.m4
@@ -58,7 +58,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 7
+#serial 8
AU_ALIAS([VL_LIB_READLINE], [AX_LIB_READLINE])
AC_DEFUN([AX_LIB_READLINE], [
@@ -73,7 +73,7 @@ AC_DEFUN([AX_LIB_READLINE], [
TRY_LIB="-l$readline_lib -l$termcap_lib"
fi
LIBS="$ORIG_LIBS $TRY_LIB"
- AC_TRY_LINK_FUNC(readline, ax_cv_lib_readline="$TRY_LIB")
+ AC_LINK_IFELSE([AC_LANG_CALL([], [readline])], [ax_cv_lib_readline="$TRY_LIB"])
if test -n "$ax_cv_lib_readline"; then
break
fi
@@ -96,7 +96,7 @@ AC_DEFUN([AX_LIB_READLINE], [
AC_CACHE_CHECK([whether readline supports history],
ax_cv_lib_readline_history, [
ax_cv_lib_readline_history="no"
- AC_TRY_LINK_FUNC(add_history, ax_cv_lib_readline_history="yes")
+ AC_LINK_IFELSE([AC_LANG_CALL([], [add_history])], [ax_cv_lib_readline_history="yes"])
])
if test "$ax_cv_lib_readline_history" = "yes"; then
AC_DEFINE(HAVE_READLINE_HISTORY, 1,