From b2e64587361578ab82bc52680acc34531139e2f8 Mon Sep 17 00:00:00 2001 From: Dmitry Podgorny Date: Sun, 5 Jan 2020 01:00:54 +0200 Subject: [PATCH] autotools: check for snprintf and vsnprintf src/snprinf.[ch] rely on HAVE_SNPRINTF macro. The check is missed in configure script and libstrophe always use internal implementation of snprinf() which may be inefficient. Add check to configure.ac. --- configure.ac | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index b28c090..a52e892 100644 --- a/configure.ac +++ b/configure.ac @@ -31,6 +31,9 @@ AC_ARG_ENABLE([tls], AC_ARG_ENABLE([cares], [AS_HELP_STRING([--enable-cares], [use c-ares for DNS resolution])]) +AC_SEARCH_LIBS([socket], [network socket]) +#AC_CHECK_FUNCS([snprintf vsnprintf]) + if test "x$enable_tls" != xno; then PKG_CHECK_MODULES([openssl], [openssl], [PC_REQUIRES="openssl ${PC_REQUIRES}"], @@ -91,8 +94,6 @@ fi AC_MSG_NOTICE([libstrophe will use the $with_parser XML parser]) -AC_SEARCH_LIBS([socket], [network socket]) - if test "x$enable_cares" = xyes; then PKG_CHECK_MODULES([libcares], [libcares >= 1.7.0], [