]> git.kaiwu.me - haproxy.git/commitdiff
BUILD: Makefile: error when trying to build with aws-lc with the wrong flags
authorWilliam Lallemand <wlallemand@haproxy.com>
Tue, 21 Jul 2026 13:06:20 +0000 (15:06 +0200)
committerWilliam Lallemand <wlallemand@haproxy.com>
Tue, 21 Jul 2026 13:19:05 +0000 (15:19 +0200)
USE_OPENSSL_AWSLC=1 is required when trying to build with aws-lc. This
was already required before, but kind of worked without it since
f76e8e50f460 ("BUILD: ssl: replace USE_OPENSSL_AWSLC by
OPENSSL_IS_AWSLC").

However since 9ac590b5 ("MEDIUM: ssl: introduce src/fips.c with TLS
version check"), this can't work by accident anymore.

This patch emits an error when we find OPENSSL_IS_AWSLC, but we didn't
found USE_OPENSSL_AWSLC=1.

include/haproxy/openssl-compat.h

index fb859263eb854c41f5254a6c6dd95803f86e275b..efdfee3435bd330199209382d99f6517a39ab062 100644 (file)
 #include <openssl/rand.h>
 #include <openssl/hmac.h>
 #include <openssl/rsa.h>
+
+#ifdef OPENSSL_IS_AWSLC
+#if !defined(USE_OPENSSL_AWSLC)
+#error "AWSLC detected but USE_OPENSSL_AWSLC=1 is not set on the make line"
+#endif
+#endif
+
 #if (defined SSL_CTRL_SET_TLSEXT_STATUS_REQ_CB && !defined OPENSSL_NO_OCSP)
 #include <openssl/ocsp.h>
 #endif