configure: sha1: check libsha1 using pkg-config instead
Previously the code was using AC_CHECK_LIB, guaranteeing whether the library is correct by tracking sha1_begin function. This paranoic checking is not necessary given there's only one libsha1 in the market, which surely contains such function. Moreover, this patch now improves a bit the sha1 implementation checking behavior using pkg-config to find the right flags that needs to link against. Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com> Reviewed-by: Mikhail Gusarov <dottedmag@dottedmag.net>
This commit is contained in:
parent
643cb6e87c
commit
c043de3261
|
@ -1380,7 +1380,7 @@ if test "x$with_sha1" = xlibmd; then
|
|||
[Use libmd SHA1 functions])
|
||||
SHA1_LIBS=-lmd
|
||||
fi
|
||||
AC_CHECK_LIB([sha1], [sha1_begin], [HAVE_LIBSHA1=yes])
|
||||
PKG_CHECK_MODULES([LIBSHA1], [sha1], [HAVE_LIBSHA1=yes], [HAVE_LIBSHA1=no])
|
||||
if test "x$with_sha1" = x && test "x$HAVE_LIBSHA1" = xyes; then
|
||||
with_sha1=libsha1
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue
Block a user