From: Eric Bollengier Date: Thu, 10 Mar 2022 10:45:06 +0000 (+0100) Subject: Add new tests to ./configure.in X-Git-Tag: Release-11.3.2~87 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1cce65dc3f9ccc05a069af290fb643574cf4200f;p=thirdparty%2Fbacula.git Add new tests to ./configure.in --- diff --git a/bacula/autoconf/configure.in b/bacula/autoconf/configure.in index a053a1cfc..88a4b44ed 100644 --- a/bacula/autoconf/configure.in +++ b/bacula/autoconf/configure.in @@ -956,7 +956,18 @@ if test "x$with_openssl_directory" != "xno"; then support_crypto="no" ] ) - + AC_TRY_LINK( + [ + #include + ], [ + SSL_CTX_set_psk_client_callback(NULL, NULL); + SSL_CTX_set_psk_server_callback(NULL, NULL); + ], [ + support_tls_psk="yes" + ], [ + support_tls_psk="no" + ] + ) AC_TRY_LINK( [ #include @@ -984,8 +995,33 @@ if test "x$with_openssl_directory" != "xno"; then ac_cv_openssl_export="yes" ] ) + AC_TRY_LINK( + [ + #include + ], [ + FIPS_mode_set(1); + ], [ + AC_DEFINE(HAVE_FIPS) + AC_MSG_RESULT([checking for FIPS... yes]) + ], [ + AC_MSG_RESULT([checkint for FIPS... no]) + ] + ) + AC_TRY_LINK( + [ + #include + ], [ + OPENSSL_VERSION_TEXT; + ], [ + AC_DEFINE(HAVE_OPENSSL_VERSION_TEXT) + ], [ + ] + ) AC_MSG_RESULT([$support_tls]) + if test "$support_tls_psk" = "yes"; then + AC_DEFINE(HAVE_TLS_PSK, 1, [Define if TLS PSK support should be enabled]) + fi if test "$support_tls" = "yes"; then AC_DEFINE(HAVE_OPENSSL, 1, [Define if OpenSSL library is available]) AC_DEFINE(HAVE_TLS, 1, [Define if TLS support should be enabled]) @@ -2480,6 +2516,8 @@ AC_CHECK_FUNCS(inet_ntop, [AC_DEFINE(HAVE_INET_NTOP)]) AC_CHECK_FUNCS(gethostbyname2, [AC_DEFINE(HAVE_GETHOSTBYNAME2)]) AC_CHECK_FUNCS(getnameinfo, [AC_DEFINE(HAVE_GETNAMEINFO)]) +dnl Check for poll() function +AC_CHECK_FUNCS(poll, [AC_DEFINE(HAVE_POLL)]) dnl ---------------------------- dnl check sa_len of sockaddr @@ -2503,6 +2541,28 @@ if test $ac_cv_struct_sockaddr_sa_len = yes; then AC_DEFINE(HAVE_SA_LEN, 1, [Define if sa_len field exists in struct sockaddr]) fi +dnl ---------------------------- +dnl check sockaddr_storage +dnl ---------------------------- +AC_CACHE_CHECK(for struct sockaddr_storage, ac_cv_struct_sockaddr_storage, + [ + AC_TRY_COMPILE( + [ + #include + ], [ + struct sockaddr_storage s; + ], [ + ac_cv_struct_sockaddr_storage=yes + ], [ac_cv_struct_sockaddr_storage=no + ] + ) + ] +) + +if test $ac_cv_struct_sockaddr_storage = yes; then + AC_DEFINE(HAVE_SOCKADDR_STORAGE, 1, [Define if struct sockaddr_storage exists]) +fi + dnl dnl check for working getaddrinfo() dnl