]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
build: do not publish `HAVE_BORINGSSL`, `HAVE_AWSLC` macros
authorViktor Szakats <commit@vsz.me>
Sun, 8 Oct 2023 15:37:41 +0000 (15:37 +0000)
committerViktor Szakats <commit@vsz.me>
Sun, 8 Oct 2023 22:29:45 +0000 (22:29 +0000)
Syncing this up with CMake.

Source code uses the built-in `OPENSSL_IS_AWSLC` and
`OPENSSL_IS_BORINSSL` macros to detect BoringSSL and AWS-LC. No help is
necessary from the build tools.

The one use of `HAVE_BORINGSSL` in the source turned out to be no longer
necessary for warning-free BoringSSL + Schannel builds. Ref: #1610 #2634

autotools detects this anyway for display purposes.
CMake detects this to decide whether to use the BoringSSL-specific
crypto lib with ngtcp2. It detects AWS-LC, but doesn't use the detection
result just yet (planned in #12066).

Ref: #11964

Reviewed-by: Daniel Stenberg
Reviewed-by: Jay Satiro
Closes #12065

CMakeLists.txt
lib/vtls/schannel.h
m4/curl-openssl.m4
winbuild/MakefileBuild.vc

index 863d126ac86f8cd63573d097b1b256fcbb01a68d..458b25550ed74abb565e842cd0100e5783ca531f 100644 (file)
@@ -52,8 +52,6 @@
 #   HAVE_SSL_SET0_WBIO: `SSL_set0_wbio` present in OpenSSL/wolfSSL
 #   HAVE_OPENSSL_SRP: `SSL_CTX_set_srp_username` present in OpenSSL/wolfSSL
 #   HAVE_GNUTLS_SRP: `gnutls_srp_verifier` present in GnuTLS
-#   HAVE_AWSLC: OpenSSL is AWS-LC
-#   HAVE_BORINGSSL: OpenSSL is BoringSSL
 #   HAVE_SSL_CTX_SET_QUIC_METHOD: `SSL_CTX_set_quic_method` present in OpenSSL/wolfSSL
 #   HAVE_QUICHE_CONN_SET_QLOG_FD: `quiche_conn_set_qlog_fd` present in QUICHE
 #   HAVE_ZSTD_CREATEDSTREAM: `ZSTD_createDStream` present in Zstd
index be235673028edf7fdaa350ac6b3b66827e2342a7..b26334bcf877a0318fb5f3291b84ee60c678d28d 100644 (file)
@@ -68,7 +68,7 @@
  * BoringSSL's <openssl/x509.h>: So just undefine those defines here
  * (and only here).
  */
-#if defined(HAVE_BORINGSSL) || defined(OPENSSL_IS_BORINGSSL)
+#if defined(OPENSSL_IS_BORINGSSL)
 # undef X509_NAME
 # undef X509_CERT_PAIR
 # undef X509_EXTENSIONS
index 83fcb1428a9636554439f9ab5450a7ff83a5fe3c..a4811d2a36d55579fea68df510ea039a3f6c3d84 100644 (file)
@@ -270,8 +270,6 @@ if test "x$OPT_OPENSSL" != xno; then
        ]])
     ],[
         AC_MSG_RESULT([yes])
-        AC_DEFINE_UNQUOTED(HAVE_BORINGSSL, 1,
-                           [Define to 1 if using BoringSSL.])
         ssl_msg="BoringSSL"
     ],[
         AC_MSG_RESULT([no])
@@ -288,8 +286,6 @@ if test "x$OPT_OPENSSL" != xno; then
        ]])
     ],[
         AC_MSG_RESULT([yes])
-        AC_DEFINE_UNQUOTED(HAVE_AWSLC, 1,
-                           [Define to 1 if using AWS-LC.])
         ssl_msg="AWS-LC"
     ],[
         AC_MSG_RESULT([no])
index b6049e832fe5c58f86ca6677e8853140482f04e4..9b165537a438f16a279283e3c5ce898e3bc75980 100644 (file)
@@ -136,9 +136,6 @@ WIN_LIBS     = $(WIN_LIBS) gdi32.lib user32.lib crypt32.lib
 \r
 !IFDEF USE_SSL\r
 SSL_CFLAGS   = /DUSE_OPENSSL /I"$(SSL_INC_DIR)"\r
-!IF EXISTS("$(SSL_INC_DIR)\is_boringssl.h")\r
-SSL_CFLAGS   = $(SSL_CFLAGS) /DHAVE_BORINGSSL\r
-!ENDIF\r
 !IF "$(ENABLE_OPENSSL_AUTO_LOAD_CONFIG)"=="false"\r
 SSL_CFLAGS   = $(SSL_CFLAGS) /DCURL_DISABLE_OPENSSL_AUTO_LOAD_CONFIG\r
 !ENDIF\r