lighttpd: build fixes

Signed-off-by: Glenn Strauss <gstrauss@gluelogic.com>
This commit is contained in:
Glenn Strauss 2023-04-30 04:11:01 -04:00 committed by Rosen Penev
parent ab94144b87
commit 90d5bd6dab
4 changed files with 78 additions and 1 deletions

View File

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=lighttpd
PKG_VERSION:=1.4.69
PKG_RELEASE:=2
PKG_RELEASE:=3
# release candidate ~rcX testing; remove for release
#PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)

View File

@ -0,0 +1,34 @@
From e91ad65e4aacde815679c06cb687931dd7beb9b3 Mon Sep 17 00:00:00 2001
From: Glenn Strauss <gstrauss@gluelogic.com>
Date: Thu, 20 Apr 2023 21:27:36 -0400
Subject: [PATCH] [meson] check FORCE_{WOLFSSL,MBEDTLS}_CRYPTO
---
src/meson.build | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
--- a/src/meson.build
+++ b/src/meson.build
@@ -358,15 +358,19 @@ if get_option('with_mbedtls')
libmbedtls = [ compiler.find_library('mbedtls') ]
libmbedx509 = [ compiler.find_library('mbedx509') ]
libmbedcrypto = [ compiler.find_library('mbedcrypto') ]
- libcrypto = [ compiler.find_library('mbedcrypto') ]
+ if compiler.get_define('FORCE_WOLFSSL_CRYPTO') == ''
+ libcrypto = [ compiler.find_library('mbedcrypto') ]
+ endif
conf_data.set('HAVE_LIBMBEDCRYPTO', true)
endif
if get_option('with_nettle')
# manual search:
# header: nettle/nettle-types.h
# function: nettle_md5_init (-lnettle)
- libcrypto = [ dependency('nettle') ]
- conf_data.set('HAVE_NETTLE_NETTLE_TYPES_H', true)
+ if compiler.get_define('FORCE_WOLFSSL_CRYPTO') == '' and compiler.get_define('FORCE_MBEDTLS_CRYPTO') == ''
+ libcrypto = [ dependency('nettle') ]
+ conf_data.set('HAVE_NETTLE_NETTLE_TYPES_H', true)
+ endif
endif
if get_option('with_gnutls')
# manual search:

View File

@ -0,0 +1,23 @@
From 37cbdacda78f9df4aba4c39e60472025d93bb7ba Mon Sep 17 00:00:00 2001
From: Glenn Strauss <gstrauss@gluelogic.com>
Date: Fri, 28 Apr 2023 03:17:16 -0400
Subject: [PATCH] [mod_mbedtls] check MBEDTLS_DEBUG_C for debug func
---
src/mod_mbedtls.c | 2 ++
1 file changed, 2 insertions(+)
--- a/src/mod_mbedtls.c
+++ b/src/mod_mbedtls.c
@@ -2357,9 +2357,11 @@ CONNECTION_FUNC(mod_mbedtls_handle_con_a
* overlap, and so this debug setting is not reset upon connection close.
* Once enabled, debug hook will remain so for this mbedtls_ssl_config */
if (hctx->conf.ssl_log_noise) {/* volume level for debug message callback */
+ #ifdef MBEDTLS_DEBUG_C
#if MBEDTLS_VERSION_NUMBER >= 0x02000000 /* mbedtls 2.0.0 */
mbedtls_debug_set_threshold(hctx->conf.ssl_log_noise);
#endif
+ #endif
mbedtls_ssl_conf_dbg(hctx->ssl_ctx, mod_mbedtls_debug_cb,
(void *)(intptr_t)hctx->conf.ssl_log_noise);
}

View File

@ -0,0 +1,20 @@
From 2fc157f37ea4644ba9ac776de1926b9e518ec42b Mon Sep 17 00:00:00 2001
From: Glenn Strauss <gstrauss@gluelogic.com>
Date: Sat, 29 Apr 2023 00:43:55 -0400
Subject: [PATCH] [meson] build fix for builtin_mods
---
src/meson.build | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
--- a/src/meson.build
+++ b/src/meson.build
@@ -656,7 +656,7 @@ executable('lighttpd-angel',
)
executable('lighttpd', configparser,
- sources: common_src + main_src,
+ sources: common_src + main_src + builtin_mods,
dependencies: [ common_flags, lighttpd_flags
, libattr
, libcrypto