mirror of
https://github.com/curl/curl.git
synced 2025-02-23 15:10:03 +08:00
configure: fix indentation
Also: - move `then`s and an `in` inline. - whitespace. Closes #14628
This commit is contained in:
parent
35034df1ca
commit
0052b4b52d
66
acinclude.m4
66
acinclude.m4
@ -580,8 +580,8 @@ dnl hosts have it, but AIX 4.3 is one known exception.
|
||||
AC_DEFUN([TYPE_SOCKADDR_STORAGE],
|
||||
[
|
||||
AC_CHECK_TYPE([struct sockaddr_storage],
|
||||
AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE, 1,
|
||||
[if struct sockaddr_storage is defined]), ,
|
||||
AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE, 1,
|
||||
[if struct sockaddr_storage is defined]), ,
|
||||
[
|
||||
#undef inline
|
||||
#ifdef _WIN32
|
||||
@ -645,9 +645,9 @@ $curl_includes_bsdsocket
|
||||
])
|
||||
#
|
||||
if test "$curl_cv_recv" = "yes"; then
|
||||
AC_DEFINE_UNQUOTED(HAVE_RECV, 1,
|
||||
[Define to 1 if you have the recv function.])
|
||||
curl_cv_func_recv="yes"
|
||||
AC_DEFINE_UNQUOTED(HAVE_RECV, 1,
|
||||
[Define to 1 if you have the recv function.])
|
||||
curl_cv_func_recv="yes"
|
||||
else
|
||||
AC_MSG_ERROR([Unable to link function recv])
|
||||
fi
|
||||
@ -1217,7 +1217,7 @@ AC_DEFUN([CURL_CHECK_CA_BUNDLE], [
|
||||
|
||||
AC_ARG_WITH(ca-bundle,
|
||||
AS_HELP_STRING([--with-ca-bundle=FILE],
|
||||
[Path to a file containing CA certificates (example: /etc/ca-bundle.crt)])
|
||||
[Path to a file containing CA certificates (example: /etc/ca-bundle.crt)])
|
||||
AS_HELP_STRING([--without-ca-bundle], [Don't use a default CA bundle]),
|
||||
[
|
||||
want_ca="$withval"
|
||||
@ -1228,7 +1228,7 @@ AS_HELP_STRING([--without-ca-bundle], [Don't use a default CA bundle]),
|
||||
[ want_ca="unset" ])
|
||||
AC_ARG_WITH(ca-path,
|
||||
AS_HELP_STRING([--with-ca-path=DIRECTORY],
|
||||
[Path to a directory containing CA certificates stored individually, with \
|
||||
[Path to a directory containing CA certificates stored individually, with \
|
||||
their filenames in a hash format. This option can be used with the OpenSSL, \
|
||||
GnuTLS, mbedTLS and wolfSSL backends. Refer to OpenSSL c_rehash for details. \
|
||||
(example: /etc/certificates)])
|
||||
@ -1368,7 +1368,7 @@ AC_DEFUN([CURL_CHECK_CA_EMBED], [
|
||||
|
||||
AC_ARG_WITH(ca-embed,
|
||||
AS_HELP_STRING([--with-ca-embed=FILE],
|
||||
[Path to a file containing CA certificates (example: /etc/ca-bundle.crt)])
|
||||
[Path to a file containing CA certificates (example: /etc/ca-bundle.crt)])
|
||||
AS_HELP_STRING([--without-ca-embed], [Don't embed a default CA bundle]),
|
||||
[
|
||||
want_ca_embed="$withval"
|
||||
@ -1495,10 +1495,10 @@ dnl variable while checking PKG_CONFIG_LIBDIR
|
||||
dnl
|
||||
|
||||
AC_DEFUN([CURL_EXPORT_PCDIR], [
|
||||
if test -n "$1"; then
|
||||
PKG_CONFIG_LIBDIR="$1"
|
||||
export PKG_CONFIG_LIBDIR
|
||||
fi
|
||||
if test -n "$1"; then
|
||||
PKG_CONFIG_LIBDIR="$1"
|
||||
export PKG_CONFIG_LIBDIR
|
||||
fi
|
||||
])
|
||||
|
||||
dnl CURL_CHECK_PKGCONFIG ($module, [$pcdir])
|
||||
@ -1513,28 +1513,28 @@ dnl Optionally PKG_CONFIG_LIBDIR may be given as $pcdir.
|
||||
dnl
|
||||
|
||||
AC_DEFUN([CURL_CHECK_PKGCONFIG], [
|
||||
if test -n "$PKG_CONFIG"; then
|
||||
PKGCONFIG="$PKG_CONFIG"
|
||||
if test -n "$PKG_CONFIG"; then
|
||||
PKGCONFIG="$PKG_CONFIG"
|
||||
else
|
||||
AC_PATH_TOOL([PKGCONFIG], [pkg-config], [no],
|
||||
[$PATH:/usr/bin:/usr/local/bin])
|
||||
fi
|
||||
|
||||
if test "x$PKGCONFIG" != "xno"; then
|
||||
AC_MSG_CHECKING([for $1 options with pkg-config])
|
||||
dnl ask pkg-config about $1
|
||||
itexists=`CURL_EXPORT_PCDIR([$2]) dnl
|
||||
$PKGCONFIG --exists $1 >/dev/null 2>&1 && echo 1`
|
||||
|
||||
if test -z "$itexists"; then
|
||||
dnl pkg-config does not have info about the given module! set the
|
||||
dnl variable to 'no'
|
||||
PKGCONFIG="no"
|
||||
AC_MSG_RESULT([no])
|
||||
else
|
||||
AC_PATH_TOOL([PKGCONFIG], [pkg-config], [no],
|
||||
[$PATH:/usr/bin:/usr/local/bin])
|
||||
fi
|
||||
|
||||
if test "x$PKGCONFIG" != "xno"; then
|
||||
AC_MSG_CHECKING([for $1 options with pkg-config])
|
||||
dnl ask pkg-config about $1
|
||||
itexists=`CURL_EXPORT_PCDIR([$2]) dnl
|
||||
$PKGCONFIG --exists $1 >/dev/null 2>&1 && echo 1`
|
||||
|
||||
if test -z "$itexists"; then
|
||||
dnl pkg-config does not have info about the given module! set the
|
||||
dnl variable to 'no'
|
||||
PKGCONFIG="no"
|
||||
AC_MSG_RESULT([no])
|
||||
else
|
||||
AC_MSG_RESULT([found])
|
||||
fi
|
||||
AC_MSG_RESULT([found])
|
||||
fi
|
||||
fi
|
||||
])
|
||||
|
||||
|
||||
@ -1676,7 +1676,7 @@ AC_DEFUN([CURL_SUPPORTS_BUILTIN_AVAILABLE], [
|
||||
],[
|
||||
AC_MSG_RESULT([yes])
|
||||
AC_DEFINE_UNQUOTED(HAVE_BUILTIN_AVAILABLE, 1,
|
||||
[Define to 1 if you have the __builtin_available function.])
|
||||
[Define to 1 if you have the __builtin_available function.])
|
||||
],[
|
||||
AC_MSG_RESULT([no])
|
||||
])
|
||||
|
1971
configure.ac
1971
configure.ac
File diff suppressed because it is too large
Load Diff
@ -852,13 +852,13 @@ AC_DEFUN([CURL_SET_COMPILER_WARNING_OPTS], [
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [enum-conversion])
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [sometimes-uninitialized])
|
||||
case $host_os in
|
||||
cygwin* | mingw*)
|
||||
dnl skip missing-variable-declarations warnings for Cygwin and
|
||||
dnl MinGW because the libtool wrapper executable causes them
|
||||
;;
|
||||
*)
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [missing-variable-declarations])
|
||||
;;
|
||||
cygwin* | mingw*)
|
||||
dnl skip missing-variable-declarations warnings for Cygwin and
|
||||
dnl MinGW because the libtool wrapper executable causes them
|
||||
;;
|
||||
*)
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [missing-variable-declarations])
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
#
|
||||
|
@ -160,10 +160,10 @@ dnl We require GnuTLS with SRP support.
|
||||
dnl ---
|
||||
if test "$GNUTLS_ENABLED" = "1"; then
|
||||
AC_CHECK_LIB(gnutls, gnutls_srp_verifier,
|
||||
[
|
||||
AC_DEFINE(HAVE_GNUTLS_SRP, 1, [if you have the function gnutls_srp_verifier])
|
||||
AC_SUBST(HAVE_GNUTLS_SRP, [1])
|
||||
])
|
||||
[
|
||||
AC_DEFINE(HAVE_GNUTLS_SRP, 1, [if you have the function gnutls_srp_verifier])
|
||||
AC_SUBST(HAVE_GNUTLS_SRP, [1])
|
||||
])
|
||||
fi
|
||||
|
||||
])
|
||||
|
@ -43,14 +43,14 @@ if test "x$OPT_MBEDTLS" != xno; then
|
||||
|
||||
AC_CHECK_LIB(mbedtls, mbedtls_havege_init,
|
||||
dnl libmbedtls found, set the variable
|
||||
[
|
||||
AC_DEFINE(USE_MBEDTLS, 1, [if mbedTLS is enabled])
|
||||
AC_SUBST(USE_MBEDTLS, [1])
|
||||
MBEDTLS_ENABLED=1
|
||||
USE_MBEDTLS="yes"
|
||||
ssl_msg="mbedTLS"
|
||||
test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
|
||||
], [], -lmbedx509 -lmbedcrypto)
|
||||
[
|
||||
AC_DEFINE(USE_MBEDTLS, 1, [if mbedTLS is enabled])
|
||||
AC_SUBST(USE_MBEDTLS, [1])
|
||||
MBEDTLS_ENABLED=1
|
||||
USE_MBEDTLS="yes"
|
||||
ssl_msg="mbedTLS"
|
||||
test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
|
||||
], [], -lmbedx509 -lmbedcrypto)
|
||||
fi
|
||||
|
||||
addld=""
|
||||
@ -66,7 +66,7 @@ if test "x$OPT_MBEDTLS" != xno; then
|
||||
|
||||
LDFLAGS="$LDFLAGS $addld"
|
||||
if test "$addcflags" != "-I/usr/include"; then
|
||||
CPPFLAGS="$CPPFLAGS $addcflags"
|
||||
CPPFLAGS="$CPPFLAGS $addcflags"
|
||||
fi
|
||||
|
||||
AC_CHECK_LIB(mbedtls, mbedtls_ssl_init,
|
||||
|
@ -61,48 +61,48 @@ if test "x$OPT_OPENSSL" != xno; then
|
||||
esac
|
||||
|
||||
case "$OPT_OPENSSL" in
|
||||
yes)
|
||||
dnl --with-openssl (without path) used
|
||||
PKGTEST="yes"
|
||||
PREFIX_OPENSSL=
|
||||
;;
|
||||
*)
|
||||
dnl check the given --with-openssl spot
|
||||
PKGTEST="no"
|
||||
PREFIX_OPENSSL=$OPT_OPENSSL
|
||||
|
||||
dnl Try pkg-config even when cross-compiling. Since we
|
||||
dnl specify PKG_CONFIG_LIBDIR we're only looking where
|
||||
dnl the user told us to look
|
||||
OPENSSL_PCDIR="$OPT_OPENSSL/lib/pkgconfig"
|
||||
if test -f "$OPENSSL_PCDIR/openssl.pc"; then
|
||||
AC_MSG_NOTICE([PKG_CONFIG_LIBDIR will be set to "$OPENSSL_PCDIR"])
|
||||
yes)
|
||||
dnl --with-openssl (without path) used
|
||||
PKGTEST="yes"
|
||||
fi
|
||||
PREFIX_OPENSSL=
|
||||
;;
|
||||
*)
|
||||
dnl check the given --with-openssl spot
|
||||
PKGTEST="no"
|
||||
PREFIX_OPENSSL=$OPT_OPENSSL
|
||||
|
||||
if test "$PKGTEST" != "yes"; then
|
||||
# try lib64 instead
|
||||
OPENSSL_PCDIR="$OPT_OPENSSL/lib64/pkgconfig"
|
||||
dnl Try pkg-config even when cross-compiling. Since we
|
||||
dnl specify PKG_CONFIG_LIBDIR we're only looking where
|
||||
dnl the user told us to look
|
||||
OPENSSL_PCDIR="$OPT_OPENSSL/lib/pkgconfig"
|
||||
if test -f "$OPENSSL_PCDIR/openssl.pc"; then
|
||||
AC_MSG_NOTICE([PKG_CONFIG_LIBDIR will be set to "$OPENSSL_PCDIR"])
|
||||
PKGTEST="yes"
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$PKGTEST" != "yes"; then
|
||||
if test ! -f "$PREFIX_OPENSSL/include/openssl/ssl.h"; then
|
||||
AC_MSG_ERROR([$PREFIX_OPENSSL is a bad --with-openssl prefix!])
|
||||
if test "$PKGTEST" != "yes"; then
|
||||
# try lib64 instead
|
||||
OPENSSL_PCDIR="$OPT_OPENSSL/lib64/pkgconfig"
|
||||
if test -f "$OPENSSL_PCDIR/openssl.pc"; then
|
||||
AC_MSG_NOTICE([PKG_CONFIG_LIBDIR will be set to "$OPENSSL_PCDIR"])
|
||||
PKGTEST="yes"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl in case pkg-config comes up empty, use what we got
|
||||
dnl via --with-openssl
|
||||
LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
|
||||
if test "$PREFIX_OPENSSL" != "/usr" ; then
|
||||
SSL_LDFLAGS="-L$LIB_OPENSSL"
|
||||
SSL_CPPFLAGS="-I$PREFIX_OPENSSL/include"
|
||||
fi
|
||||
;;
|
||||
if test "$PKGTEST" != "yes"; then
|
||||
if test ! -f "$PREFIX_OPENSSL/include/openssl/ssl.h"; then
|
||||
AC_MSG_ERROR([$PREFIX_OPENSSL is a bad --with-openssl prefix!])
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl in case pkg-config comes up empty, use what we got
|
||||
dnl via --with-openssl
|
||||
LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
|
||||
if test "$PREFIX_OPENSSL" != "/usr" ; then
|
||||
SSL_LDFLAGS="-L$LIB_OPENSSL"
|
||||
SSL_CPPFLAGS="-I$PREFIX_OPENSSL/include"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if test "$PKGTEST" = "yes"; then
|
||||
@ -207,18 +207,18 @@ if test "x$OPT_OPENSSL" != xno; then
|
||||
AC_CHECK_LIB(ssl, SSL_connect)
|
||||
|
||||
if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
|
||||
dnl we didn't find the SSL lib, try the RSAglue/rsaref stuff
|
||||
AC_MSG_CHECKING(for ssl with RSAglue/rsaref libs in use);
|
||||
OLIBS=$LIBS
|
||||
LIBS="-lRSAglue -lrsaref $LIBS"
|
||||
AC_CHECK_LIB(ssl, SSL_connect)
|
||||
if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
|
||||
dnl still no SSL_connect
|
||||
AC_MSG_RESULT(no)
|
||||
LIBS=$OLIBS
|
||||
else
|
||||
AC_MSG_RESULT(yes)
|
||||
fi
|
||||
dnl we didn't find the SSL lib, try the RSAglue/rsaref stuff
|
||||
AC_MSG_CHECKING(for ssl with RSAglue/rsaref libs in use);
|
||||
OLIBS=$LIBS
|
||||
LIBS="-lRSAglue -lrsaref $LIBS"
|
||||
AC_CHECK_LIB(ssl, SSL_connect)
|
||||
if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
|
||||
dnl still no SSL_connect
|
||||
AC_MSG_RESULT(no)
|
||||
LIBS=$OLIBS
|
||||
else
|
||||
AC_MSG_RESULT(yes)
|
||||
fi
|
||||
|
||||
else
|
||||
|
||||
@ -247,7 +247,7 @@ if test "x$OPT_OPENSSL" != xno; then
|
||||
fi
|
||||
|
||||
if test X"$OPENSSL_ENABLED" != X"1"; then
|
||||
LIBS="$CLEANLIBS"
|
||||
LIBS="$CLEANLIBS"
|
||||
fi
|
||||
|
||||
if test X"$OPT_OPENSSL" != Xoff &&
|
||||
@ -261,36 +261,36 @@ if test "x$OPT_OPENSSL" != xno; then
|
||||
|
||||
AC_MSG_CHECKING([for BoringSSL])
|
||||
AC_COMPILE_IFELSE([
|
||||
AC_LANG_PROGRAM([[
|
||||
#include <openssl/base.h>
|
||||
]],[[
|
||||
#ifndef OPENSSL_IS_BORINGSSL
|
||||
#error not boringssl
|
||||
#endif
|
||||
]])
|
||||
AC_LANG_PROGRAM([[
|
||||
#include <openssl/base.h>
|
||||
]],[[
|
||||
#ifndef OPENSSL_IS_BORINGSSL
|
||||
#error not boringssl
|
||||
#endif
|
||||
]])
|
||||
],[
|
||||
AC_MSG_RESULT([yes])
|
||||
ssl_msg="BoringSSL"
|
||||
OPENSSL_IS_BORINGSSL=1
|
||||
AC_MSG_RESULT([yes])
|
||||
ssl_msg="BoringSSL"
|
||||
OPENSSL_IS_BORINGSSL=1
|
||||
],[
|
||||
AC_MSG_RESULT([no])
|
||||
AC_MSG_RESULT([no])
|
||||
])
|
||||
|
||||
AC_MSG_CHECKING([for AWS-LC])
|
||||
AC_COMPILE_IFELSE([
|
||||
AC_LANG_PROGRAM([[
|
||||
#include <openssl/base.h>
|
||||
]],[[
|
||||
#ifndef OPENSSL_IS_AWSLC
|
||||
#error not AWS-LC
|
||||
#endif
|
||||
]])
|
||||
AC_LANG_PROGRAM([[
|
||||
#include <openssl/base.h>
|
||||
]],[[
|
||||
#ifndef OPENSSL_IS_AWSLC
|
||||
#error not AWS-LC
|
||||
#endif
|
||||
]])
|
||||
],[
|
||||
AC_MSG_RESULT([yes])
|
||||
ssl_msg="AWS-LC"
|
||||
OPENSSL_IS_BORINGSSL=1
|
||||
AC_MSG_RESULT([yes])
|
||||
ssl_msg="AWS-LC"
|
||||
OPENSSL_IS_BORINGSSL=1
|
||||
],[
|
||||
AC_MSG_RESULT([no])
|
||||
AC_MSG_RESULT([no])
|
||||
])
|
||||
|
||||
AC_MSG_CHECKING([for LibreSSL])
|
||||
@ -373,20 +373,20 @@ if test X"$OPENSSL_ENABLED" = X"1"; then
|
||||
AC_ARG_WITH(random,
|
||||
AS_HELP_STRING([--with-random=FILE],
|
||||
[read randomness from FILE (default=/dev/urandom)]),
|
||||
[ RANDOM_FILE="$withval" ],
|
||||
[
|
||||
if test x$cross_compiling != xyes; then
|
||||
dnl Check for random device
|
||||
AC_CHECK_FILE("/dev/urandom", [ RANDOM_FILE="/dev/urandom"] )
|
||||
else
|
||||
AC_MSG_WARN([skipped the /dev/urandom detection when cross-compiling])
|
||||
fi
|
||||
]
|
||||
[ RANDOM_FILE="$withval" ],
|
||||
[
|
||||
if test x$cross_compiling != xyes; then
|
||||
dnl Check for random device
|
||||
AC_CHECK_FILE("/dev/urandom", [ RANDOM_FILE="/dev/urandom"] )
|
||||
else
|
||||
AC_MSG_WARN([skipped the /dev/urandom detection when cross-compiling])
|
||||
fi
|
||||
]
|
||||
)
|
||||
if test -n "$RANDOM_FILE" && test X"$RANDOM_FILE" != Xno ; then
|
||||
AC_SUBST(RANDOM_FILE)
|
||||
AC_DEFINE_UNQUOTED(RANDOM_FILE, "$RANDOM_FILE",
|
||||
[a suitable file to read random data from])
|
||||
if test -n "$RANDOM_FILE" && test X"$RANDOM_FILE" != Xno; then
|
||||
AC_SUBST(RANDOM_FILE)
|
||||
AC_DEFINE_UNQUOTED(RANDOM_FILE, "$RANDOM_FILE",
|
||||
[a suitable file to read random data from])
|
||||
fi
|
||||
fi
|
||||
|
||||
|
@ -138,18 +138,18 @@ if test "x$OPT_WOLFSSL" != xno; then
|
||||
dnl OpenSSL API root as well
|
||||
AC_CHECK_FUNC(wolfSSL_DES_ecb_encrypt,
|
||||
[
|
||||
AC_DEFINE(HAVE_WOLFSSL_DES_ECB_ENCRYPT, 1,
|
||||
[if you have wolfSSL_DES_ecb_encrypt])
|
||||
WOLFSSL_NTLM=1
|
||||
AC_DEFINE(HAVE_WOLFSSL_DES_ECB_ENCRYPT, 1,
|
||||
[if you have wolfSSL_DES_ecb_encrypt])
|
||||
WOLFSSL_NTLM=1
|
||||
]
|
||||
)
|
||||
|
||||
dnl if this symbol is present, we can make use of BIO filter chains
|
||||
AC_CHECK_FUNC(wolfSSL_BIO_set_shutdown,
|
||||
[
|
||||
AC_DEFINE(HAVE_WOLFSSL_FULL_BIO, 1,
|
||||
[if you have wolfSSL_BIO_set_shutdown])
|
||||
WOLFSSL_FULL_BIO=1
|
||||
AC_DEFINE(HAVE_WOLFSSL_FULL_BIO, 1,
|
||||
[if you have wolfSSL_BIO_set_shutdown])
|
||||
WOLFSSL_FULL_BIO=1
|
||||
]
|
||||
)
|
||||
|
||||
@ -166,7 +166,7 @@ if test "x$OPT_WOLFSSL" != xno; then
|
||||
fi
|
||||
LIBCURL_PC_REQUIRES_PRIVATE="$LIBCURL_PC_REQUIRES_PRIVATE wolfssl"
|
||||
else
|
||||
AC_MSG_ERROR([--with-wolfssl but wolfSSL was not found or doesn't work])
|
||||
AC_MSG_ERROR([--with-wolfssl but wolfSSL was not found or doesn't work])
|
||||
fi
|
||||
|
||||
fi dnl wolfSSL not disabled
|
||||
|
Loading…
Reference in New Issue
Block a user