Part of this went upstream as https://github.com/uim/uim/commit/99fd890fa601b81ff99e5e0f1977fe309f56b90e. The rest was done in https://github.com/uim/uim/pull/198. --- a/configure.ac +++ b/configure.ac @@ -601,6 +601,7 @@ if test "x$ac_cv_func_snprintf" = xyes; then AC_RUN_IFELSE( [AC_LANG_SOURCE([[ #include +#include int main(void){char b[5];snprintf(b,5,"123456789");exit(b[4]!='\0');} ]])], [AC_MSG_RESULT(yes)], --- a/m4/openssl.m4 +++ b/m4/openssl.m4 @@ -76,6 +76,7 @@ AC_MSG_CHECKING([OpenSSL header version]) AC_RUN_IFELSE( [AC_LANG_SOURCE([[ #include +#include #include #include #define DATA "conftest.sslincver" @@ -156,7 +157,9 @@ AC_ARG_WITH(openssl-header-check, AC_MSG_CHECKING([whether OpenSSL's headers match the library]) AC_RUN_IFELSE( [AC_LANG_SOURCE([[ +#include #include +#include #include int main(void) { exit(SSLeay() == OPENSSL_VERSION_NUMBER ? 0 : 1); } ]])], @@ -220,8 +223,8 @@ int main(void) { DTLSv1_method(); } AC_MSG_CHECKING([if programs using OpenSSL functions will link]) AC_LINK_IFELSE( [AC_LANG_SOURCE([[ -#include -int main(void) { SSLeay_add_all_algorithms(); } +#include +int main(void) { OpenSSL_version_num(); } ]])], [ AC_MSG_RESULT(yes)