PKG_CHECK_MODULES: Check if $pkg_cv_[]$1[]_LIBS works
Alan Modra
amodra@gmail.com
Tue Jul 28 14:02:05 GMT 2020
And this fixes the failure, but it's not very elegant, so I'm not
going to commit it. You really should only be doing the extra
AC_TRY_LINK if debuginfod.so was added to libs.
diff --git a/binutils/configure b/binutils/configure
index 4620a6b105..78a425cfbf 100755
--- a/binutils/configure
+++ b/binutils/configure
@@ -12453,7 +12453,7 @@ return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
- pkg_failed=no
+
else
pkg_failed=yes
fi
diff --git a/config/pkg.m4 b/config/pkg.m4
index 45587e97c8..cb6b917375 100644
--- a/config/pkg.m4
+++ b/config/pkg.m4
@@ -150,7 +150,7 @@ _PKG_CONFIG([$1][_LIBS], [libs], [$2])
dnl Check whether $pkg_cv_[]$1[]_LIBS works.
pkg_save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS $pkg_cv_[]$1[]_LIBS"
-AC_TRY_LINK([],[return 0;], [pkg_failed=no], [pkg_failed=yes])
+AC_TRY_LINK([],[return 0;],,[pkg_failed=yes])
LDFLAGS=$pkg_save_LDFLAGS
m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
diff --git a/gdb/configure b/gdb/configure
index eb38aaacfc..9016661692 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -7051,7 +7051,7 @@ return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
- pkg_failed=no
+
else
pkg_failed=yes
fi
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list