summaryrefslogtreecommitdiff
path: root/m4/ax_ext_have_lib.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_ext_have_lib.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_ext_have_lib.m4')
-rw-r--r--m4/ax_ext_have_lib.m44
1 files changed, 2 insertions, 2 deletions
diff --git a/m4/ax_ext_have_lib.m4 b/m4/ax_ext_have_lib.m4
index 9edb6d1..9628b4c 100644
--- a/m4/ax_ext_have_lib.m4
+++ b/m4/ax_ext_have_lib.m4
@@ -38,7 +38,7 @@
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 12
+#serial 13
AC_DEFUN([AX_EXT_HAVE_LIB],
[
@@ -55,7 +55,7 @@ AC_CACHE_CHECK([for $2 library with -L$dir], [ext_cv${ext_haslib_cvdir}_haslib_$
ext_func_save_ldflags=${LDFLAGS}
LIBS="-l$2 $4 ${ext_func_search_save_LIBS}"
LDFLAGS="-L$dir ${ext_func_save_ldflags}"
-AC_TRY_LINK_FUNC([$3], [eval "ext_cv${ext_haslib_cvdir}_haslib_$2"="yes"],
+AC_LINK_IFELSE([AC_LANG_CALL([], [$3])], [eval "ext_cv${ext_haslib_cvdir}_haslib_$2"="yes"],
[eval "ext_cv${ext_haslib_cvdir}_haslib_$2"="no"])
LIBS=$ext_func_search_save_LIBS
LDFLAGS=$ext_func_save_ldflags