summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2019-03-08 00:06:59 +0000
committerDaniel Stenberg <daniel@haxx.se>2019-03-15 10:22:42 +0100
commit1e853653d2022bec831af62ec55765e6df62e356 (patch)
tree4aa6c5692f27358bd4516ddbfc21a385643c89c4 /configure.ac
parent76a9d8df0e03d2e0a648d882a62e08c90f994f88 (diff)
downloadcurl-1e853653d2022bec831af62ec55765e6df62e356.tar.gz
configure: add --with-amissl
AmiSSL is an Amiga native library which provides a wrapper over OpenSSL. It also requires all programs using it to use bsdsocket.library directly, rather than accessing socket functions through clib, which libcurl was not necessarily doing previously. Configure will now check for the headers and ensure they are included if found. Closes #3677
Diffstat (limited to 'configure.ac')
-rwxr-xr-xconfigure.ac59
1 files changed, 56 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index 3707a886e..6d5ec2c0f 100755
--- a/configure.ac
+++ b/configure.ac
@@ -155,7 +155,7 @@ AC_SUBST(PKGADD_VENDOR)
dnl
dnl initialize all the info variables
- curl_ssl_msg="no (--with-{ssl,gnutls,nss,polarssl,mbedtls,cyassl,schannel,secure-transport,mesalink} )"
+ curl_ssl_msg="no (--with-{ssl,gnutls,nss,polarssl,mbedtls,cyassl,schannel,secure-transport,mesalink,amissl} )"
curl_ssh_msg="no (--with-libssh2)"
curl_zlib_msg="no (--with-zlib)"
curl_brotli_msg="no (--with-brotli)"
@@ -365,6 +365,7 @@ CURL_CHECK_WIN32_LARGEFILE
CURL_MAC_CFLAGS
CURL_SUPPORTS_BUILTIN_AVAILABLE
+
dnl ************************************************************
dnl switch off particular protocols
dnl
@@ -839,6 +840,28 @@ fi
if test "$HAVE_GETHOSTBYNAME" != "1"
then
+ dnl This is for AmigaOS with bsdsocket.library - needs testing before -lnet
+ AC_MSG_CHECKING([for gethostbyname for AmigaOS bsdsocket.library])
+ AC_LINK_IFELSE([
+ AC_LANG_PROGRAM([[
+#include <proto/bsdsocket.h>
+struct Library *SocketBase = NULL;
+ ]],[[
+ gethostbyname("www.dummysite.com");
+ ]])
+ ],[
+ AC_MSG_RESULT([yes])
+ HAVE_GETHOSTBYNAME="1"
+ HAVE_PROTO_BSDSOCKET_H="1"
+ AC_DEFINE(HAVE_PROTO_BSDSOCKET_H, 1, [if Amiga bsdsocket.library is in use])
+ AC_SUBST(HAVE_PROTO_BSDSOCKET_H, [1])
+ ],[
+ AC_MSG_RESULT([no])
+ ])
+fi
+
+if test "$HAVE_GETHOSTBYNAME" != "1"
+then
dnl gethostbyname in the network lib - for Haiku OS
AC_CHECK_LIB(network, gethostbyname,
[HAVE_GETHOSTBYNAME="1"
@@ -1539,6 +1562,35 @@ else
AC_MSG_RESULT(no)
fi
+OPT_AMISSL=no
+AC_ARG_WITH(amissl,dnl
+AC_HELP_STRING([--with-amissl],[enable Amiga native SSL/TLS (AmiSSL)])
+AC_HELP_STRING([--without-amissl], [disable Amiga native SSL/TLS (AmiSSL)]),
+ OPT_AMISSL=$withval)
+
+AC_MSG_CHECKING([whether to enable Amiga native SSL/TLS (AmiSSL)])
+if test "$HAVE_PROTO_BSDSOCKET_H" == "1"; then
+ if test -z "$ssl_backends" -o "x$OPT_AMISSL" != xno; then
+ ssl_msg=
+ if test "x$OPT_AMISSL" != "xno"; then
+ AC_MSG_RESULT(yes)
+ ssl_msg="AmiSSL"
+ test amissl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
+ AMISSL_ENABLED=1
+ LIBS="-lamisslauto $LIBS"
+ AC_DEFINE(USE_AMISSL, 1, [if AmiSSL is in use])
+ AC_DEFINE(USE_OPENSSL, 1, [if OpenSSL is in use])
+ else
+ AC_MSG_RESULT(no)
+ fi
+ test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
+ else
+ AC_MSG_RESULT(no)
+ fi
+else
+ AC_MSG_RESULT(no)
+fi
+
dnl **********************************************************************
dnl Check for the presence of SSL libraries and headers
dnl **********************************************************************
@@ -2638,10 +2690,10 @@ if test -z "$ssl_backends" -o "x$OPT_NSS" != xno; then
test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
fi
-case "x$OPENSSL_ENABLED$GNUTLS_ENABLED$NSS_ENABLED$POLARSSL_ENABLED$MBEDTLS_ENABLED$CYASSL_ENABLED$WINSSL_ENABLED$SECURETRANSPORT_ENABLED$MESALINK_ENABLED" in
+case "x$OPENSSL_ENABLED$GNUTLS_ENABLED$NSS_ENABLED$POLARSSL_ENABLED$MBEDTLS_ENABLED$CYASSL_ENABLED$WINSSL_ENABLED$SECURETRANSPORT_ENABLED$MESALINK_ENABLED$AMISSL_ENABLED" in
x)
AC_MSG_WARN([SSL disabled, you will not be able to use HTTPS, FTPS, NTLM and more.])
- AC_MSG_WARN([Use --with-ssl, --with-gnutls, --with-polarssl, --with-cyassl, --with-nss, --with-schannel, --with-secure-transport, or --with-mesalink to address this.])
+ AC_MSG_WARN([Use --with-ssl, --with-gnutls, --with-polarssl, --with-cyassl, --with-nss, --with-schannel, --with-secure-transport, --with-mesalink or --with-amissl to address this.])
;;
x1)
# one SSL backend is enabled
@@ -3522,6 +3574,7 @@ dnl default includes
]
)
+
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
CURL_CHECK_VARIADIC_MACROS