From 2ec6df59bf9bb8f90539114e493f62625f463b8d Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Fri, 24 Oct 2025 10:42:06 +0200 Subject: [PATCH] BUILD: openssl-compat: fix build failure with OPENSSL=0 and KTLS=1 The USE_KTLS test is currently being done outside of the USE_OPENSSL guard so disabling USE_OPENSSL still results in build failures on libcs built with support for kernels before 4.17, because we enable KTLS by default on linux. Let's move the KTLS block inside the USE_OPENSSL guard instead. No backport is needed since KTLS is only in 3.3. --- include/haproxy/openssl-compat.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/haproxy/openssl-compat.h b/include/haproxy/openssl-compat.h index ffced37cd..8ff7872ce 100644 --- a/include/haproxy/openssl-compat.h +++ b/include/haproxy/openssl-compat.h @@ -553,8 +553,6 @@ static inline unsigned long ERR_peek_error_func(const char **func) *(cb) = (void (*) (void))ctx->tlsext_status_cb #endif -#endif /* USE_OPENSSL */ - #ifdef USE_KTLS #ifdef __linux__ @@ -585,4 +583,6 @@ static inline unsigned long ERR_peek_error_func(const char **func) #endif /* USE_KTLS */ +#endif /* USE_OPENSSL */ + #endif /* _HAPROXY_OPENSSL_COMPAT_H */