summaryrefslogtreecommitdiff
path: root/net-misc/curl/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-05-23 00:06:40 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-05-23 00:06:40 +0100
commitb3b92de25c3fc5f6bddc5e513027140591a0b2a5 (patch)
treef2ce6d7e747abea3e8fa7d99e32ad5d98cf33988 /net-misc/curl/files
parent236e75597883501f8700d9ba1a5c8276f578a17f (diff)
gentoo auto-resync : 23:05:2024 - 00:06:39
Diffstat (limited to 'net-misc/curl/files')
-rw-r--r--net-misc/curl/files/curl-8.5.0-ipv6-configure-c99.patch31
-rw-r--r--net-misc/curl/files/curl-8.5.0-mpd-stream-http-adjust_pollset.patch69
-rw-r--r--net-misc/curl/files/curl-8.6.0-rustls-fixes.patch252
-rw-r--r--net-misc/curl/files/curl-8.6.0-vtls-revert-receive-max-buffer-add-test-case.patch68
-rw-r--r--net-misc/curl/files/curl-8.8.0-install-manpage.patch22
-rw-r--r--net-misc/curl/files/curl-8.8.0-mbedtls.patch42
-rw-r--r--net-misc/curl/files/curl-prefix-2.patch34
7 files changed, 98 insertions, 420 deletions
diff --git a/net-misc/curl/files/curl-8.5.0-ipv6-configure-c99.patch b/net-misc/curl/files/curl-8.5.0-ipv6-configure-c99.patch
deleted file mode 100644
index 68830f8f4717..000000000000
--- a/net-misc/curl/files/curl-8.5.0-ipv6-configure-c99.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-https://github.com/curl/curl/commit/ae75db3527461248b0a7b1686df52200d28d83b9
-
-From ae75db3527461248b0a7b1686df52200d28d83b9 Mon Sep 17 00:00:00 2001
-From: annalee <150648636+a-n-n-a-l-e-e@users.noreply.github.com>
-Date: Fri, 29 Dec 2023 05:43:33 +0000
-Subject: [PATCH] configure: fix no default int compile error in ipv6 detection
-
-Closes #12607
---- a/configure.ac
-+++ b/configure.ac
-@@ -1655,15 +1655,12 @@ AS_HELP_STRING([--disable-ipv6],[Disable IPv6 support]),
- # include <netinet/in6.h>
- #endif
- #endif
--#include <stdlib.h> /* for exit() */
--main()
-+
-+int main(void)
- {
- struct sockaddr_in6 s;
- (void)s;
-- if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
-- exit(1);
-- else
-- exit(0);
-+ return socket(AF_INET6, SOCK_STREAM, 0) < 0;
- }
- ]])
- ],
-
-
diff --git a/net-misc/curl/files/curl-8.5.0-mpd-stream-http-adjust_pollset.patch b/net-misc/curl/files/curl-8.5.0-mpd-stream-http-adjust_pollset.patch
deleted file mode 100644
index 79a16a2cc7b4..000000000000
--- a/net-misc/curl/files/curl-8.5.0-mpd-stream-http-adjust_pollset.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-https://github.com/MusicPlayerDaemon/MPD/issues/1952
-https://github.com/curl/curl/issues/12632
-https://github.com/curl/curl/commit/8e2d7b9fa4264b94bd1d9838c84d16e4cd33fbea
-
-From 8e2d7b9fa4264b94bd1d9838c84d16e4cd33fbea Mon Sep 17 00:00:00 2001
-From: Stefan Eissing <stefan@eissing.org>
-Date: Thu, 4 Jan 2024 10:06:17 +0100
-Subject: [PATCH] http: adjust_pollset fix
-
-do not add a socket for POLLIN when the transfer does not want to send
-(for example is paused).
-
-Follow-up to 47f5b1a
-
-Reported-by: bubbleguuum on github
-Fixes #12632
-Closes #12633
---- a/lib/cf-socket.c
-+++ b/lib/cf-socket.c
-@@ -1243,7 +1243,7 @@ static void cf_socket_adjust_pollset(struct Curl_cfilter *cf,
- if(ctx->sock != CURL_SOCKET_BAD) {
- if(!cf->connected)
- Curl_pollset_set_out_only(data, ps, ctx->sock);
-- else
-+ else if(CURL_WANT_RECV(data))
- Curl_pollset_add_in(data, ps, ctx->sock);
- CURL_TRC_CF(data, cf, "adjust_pollset -> %d socks", ps->num);
- }
---- a/lib/http2.c
-+++ b/lib/http2.c
-@@ -2341,8 +2341,8 @@ static void cf_h2_adjust_pollset(struct Curl_cfilter *cf,
- bool c_exhaust, s_exhaust;
-
- CF_DATA_SAVE(save, cf, data);
-- c_exhaust = !nghttp2_session_get_remote_window_size(ctx->h2);
-- s_exhaust = stream && stream->id >= 0 &&
-+ c_exhaust = want_send && !nghttp2_session_get_remote_window_size(ctx->h2);
-+ s_exhaust = want_send && stream && stream->id >= 0 &&
- !nghttp2_session_get_stream_remote_window_size(ctx->h2,
- stream->id);
- want_recv = (want_recv || c_exhaust || s_exhaust);
---- a/lib/vquic/curl_ngtcp2.c
-+++ b/lib/vquic/curl_ngtcp2.c
-@@ -1166,9 +1166,10 @@ static void cf_ngtcp2_adjust_pollset(struct Curl_cfilter *cf,
- bool c_exhaust, s_exhaust;
-
- CF_DATA_SAVE(save, cf, data);
-- c_exhaust = !ngtcp2_conn_get_cwnd_left(ctx->qconn) ||
-- !ngtcp2_conn_get_max_data_left(ctx->qconn);
-- s_exhaust = stream && stream->id >= 0 && stream->quic_flow_blocked;
-+ c_exhaust = want_send && (!ngtcp2_conn_get_cwnd_left(ctx->qconn) ||
-+ !ngtcp2_conn_get_max_data_left(ctx->qconn));
-+ s_exhaust = want_send && stream && stream->id >= 0 &&
-+ stream->quic_flow_blocked;
- want_recv = (want_recv || c_exhaust || s_exhaust);
- want_send = (!s_exhaust && want_send) ||
- !Curl_bufq_is_empty(&ctx->q.sendbuf);
---- a/lib/vquic/curl_quiche.c
-+++ b/lib/vquic/curl_quiche.c
-@@ -1189,7 +1189,7 @@ static void cf_quiche_adjust_pollset(struct Curl_cfilter *cf,
-
- c_exhaust = FALSE; /* Have not found any call in quiche that tells
- us if the connection itself is blocked */
-- s_exhaust = stream && stream->id >= 0 &&
-+ s_exhaust = want_send && stream && stream->id >= 0 &&
- (stream->quic_flow_blocked || !stream_is_writeable(cf, data));
- want_recv = (want_recv || c_exhaust || s_exhaust);
- want_send = (!s_exhaust && want_send) ||
-
diff --git a/net-misc/curl/files/curl-8.6.0-rustls-fixes.patch b/net-misc/curl/files/curl-8.6.0-rustls-fixes.patch
deleted file mode 100644
index 4f713668fd35..000000000000
--- a/net-misc/curl/files/curl-8.6.0-rustls-fixes.patch
+++ /dev/null
@@ -1,252 +0,0 @@
-From a59683a3607bc0167ff702352d15eee1c0d658a6 Mon Sep 17 00:00:00 2001
-From: Matt Jolly <Matt.Jolly@footclan.ninja>
-Date: Mon, 1 Apr 2024 08:49:27 +1000
-Subject: [PATCH] m4: fix rustls builds
-
-This patch consolidates the following commits to do with rustls
-detection using pkg-config:
-
-- https://github.com/curl/curl/commit/9c4209837094781d5eef69ae6bcad0e86b64bf99
-- https://github.com/curl/curl/commit/5a50cb5a18a141a463148562dab83fa3be1a3b90
----
- m4/curl-rustls.m4 | 210 ++++++++++++++++++++++++++++++++--------------
- 1 file changed, 146 insertions(+), 64 deletions(-)
-
-diff --git a/m4/curl-rustls.m4 b/m4/curl-rustls.m4
-index 75542e4..8082cf9 100644
---- a/m4/curl-rustls.m4
-+++ b/m4/curl-rustls.m4
-@@ -28,84 +28,166 @@ dnl check for rustls
- dnl ----------------------------------------------------
-
- if test "x$OPT_RUSTLS" != xno; then
-- _cppflags=$CPPFLAGS
-- _ldflags=$LDFLAGS
- ssl_msg=
-
-- if test X"$OPT_RUSTLS" != Xno; then
-+ dnl backup the pre-ssl variables
-+ CLEANLDFLAGS="$LDFLAGS"
-+ CLEANCPPFLAGS="$CPPFLAGS"
-
-- if test "$OPT_RUSTLS" = "yes"; then
-- OPT_RUSTLS=""
-- fi
-+ case $host_os in
-+ darwin*)
-+ LDFLAGS="$LDFLAGS -framework Security"
-+ ;;
-+ *)
-+ ;;
-+ esac
-+ ## NEW CODE
-
-- case $host_os in
-- darwin*)
-- LDFLAGS="$LDFLAGS -framework Security"
-- ;;
-- *)
-- ;;
-- esac
--
-- if test -z "$OPT_RUSTLS" ; then
-- dnl check for lib first without setting any new path
--
-- AC_CHECK_LIB(rustls, rustls_client_session_read,
-- dnl librustls found, set the variable
-- [
-- AC_DEFINE(USE_RUSTLS, 1, [if rustls is enabled])
-- AC_SUBST(USE_RUSTLS, [1])
-- RUSTLS_ENABLED=1
-- USE_RUSTLS="yes"
-- ssl_msg="rustls"
-- test rustls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
-- ], [], -lpthread -ldl -lm)
-- fi
-+ dnl use pkg-config unless we have been given a path
-+ dnl even then, try pkg-config first
-
-- if test "x$USE_RUSTLS" != "xyes"; then
-- dnl add the path and test again
-- addld=-L$OPT_RUSTLS/lib$libsuff
-- addcflags=-I$OPT_RUSTLS/include
-- rustlslib=$OPT_RUSTLS/lib$libsuff
-+ case "$OPT_RUSTLS" in
-+ yes)
-+ dnl --with-rustls (without path) used
-+ PKGTEST="yes"
-+ PREFIX_RUSTLS=
-+ ;;
-+ *)
-+ dnl check the provided --with-rustls path
-+ PKGTEST="no"
-+ PREFIX_RUSTLS=$OPT_RUSTLS
-
-- LDFLAGS="$LDFLAGS $addld"
-- if test "$addcflags" != "-I/usr/include"; then
-- CPPFLAGS="$CPPFLAGS $addcflags"
-+ dnl Try pkg-config even when cross-compiling. Since we
-+ dnl specify PKG_CONFIG_LIBDIR we are only looking where
-+ dnl the user told us to look
-+
-+ RUSTLS_PCDIR="$PREFIX_RUSTLS/lib/pkgconfig"
-+ if test -f "$RUSTLS_PCDIR/rustls.pc"; then
-+ AC_MSG_NOTICE([PKG_CONFIG_LIBDIR will be set to "$RUSTLS_PCDIR"])
-+ PKGTEST="yes"
- fi
-
-- AC_CHECK_LIB(rustls, rustls_connection_read,
-- [
-- AC_DEFINE(USE_RUSTLS, 1, [if rustls is enabled])
-- AC_SUBST(USE_RUSTLS, [1])
-- RUSTLS_ENABLED=1
-- USE_RUSTLS="yes"
-- ssl_msg="rustls"
-- test rustls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
-- ],
-- AC_MSG_ERROR([--with-rustls was specified but could not find rustls.]),
-- -lpthread -ldl -lm)
-- fi
-+ if test "$PKGTEST" != "yes"; then
-+ # try lib64 instead
-+ RUSTLS_PCDIR="$PREFIX_RUSTLS/lib64/pkgconfig"
-+ if test -f "$RUSTLS_PCDIR/rustls.pc"; then
-+ AC_MSG_NOTICE([PKG_CONFIG_LIBDIR will be set to "$RUSTLS_PCDIR"])
-+ PKGTEST="yes"
-+ fi
-+ fi
-+
-+ if test "$PKGTEST" != "yes"; then
-+ dnl pkg-config came up empty, use what we got
-+ dnl via --with-rustls
-
-- if test "x$USE_RUSTLS" = "xyes"; then
-- AC_MSG_NOTICE([detected rustls])
-- check_for_ca_bundle=1
--
-- LIBS="-lrustls -lpthread -ldl -lm $LIBS"
--
-- if test -n "$rustlslib"; then
-- dnl when shared libs were found in a path that the run-time
-- dnl linker doesn't search through, we need to add it to
-- dnl CURL_LIBRARY_PATH to prevent further configure tests to fail
-- dnl due to this
-- if test "x$cross_compiling" != "xyes"; then
-- CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$rustlslib"
-- export CURL_LIBRARY_PATH
-- AC_MSG_NOTICE([Added $rustlslib to CURL_LIBRARY_PATH])
-+ addld=-L$PREFIX_RUSTLS/lib$libsuff
-+ addcflags=-I$PREFIX_RUSTLS/include
-+
-+ LDFLAGS="$LDFLAGS $addld"
-+ if test "$addcflags" != "-I/usr/include"; then
-+ CPPFLAGS="$CPPFLAGS $addcflags"
-+ fi
-+
-+ AC_CHECK_LIB(rustls, rustls_connection_read,
-+ [
-+ AC_DEFINE(USE_RUSTLS, 1, [if rustls is enabled])
-+ AC_SUBST(USE_RUSTLS, [1])
-+ RUSTLS_ENABLED=1
-+ USE_RUSTLS="yes"
-+ ssl_msg="rustls"
-+ test rustls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
-+ ],
-+ AC_MSG_ERROR([--with-rustls was specified but could not find rustls.]),
-+ -lpthread -ldl -lm)
-+
-+ USE_RUSTLS="yes"
-+ ssl_msg="rustls"
-+
-+ LIB_RUSTLS="$PREFIX_RUSTLS/lib$libsuff"
-+ if test "$PREFIX_RUSTLS" != "/usr" ; then
-+ SSL_LDFLAGS="-L$LIB_RUSTLS"
-+ SSL_CPPFLAGS="-I$PREFIX_RUSTLS/include"
- fi
- fi
-+ ;;
-+ esac
-+
-+ if test "$PKGTEST" = "yes"; then
-+
-+ CURL_CHECK_PKGCONFIG(rustls, [$RUSTLS_PCDIR])
-+
-+ if test "$PKGCONFIG" != "no" ; then
-+ SSL_LIBS=`CURL_EXPORT_PCDIR([$RUSTLS_PCDIR]) dnl
-+ $PKGCONFIG --libs-only-l --libs-only-other rustls 2>/dev/null`
-+
-+ SSL_LDFLAGS=`CURL_EXPORT_PCDIR([$RUSTLS_PCDIR]) dnl
-+ $PKGCONFIG --libs-only-L rustls 2>/dev/null`
-+
-+ SSL_CPPFLAGS=`CURL_EXPORT_PCDIR([$RUSTLS_PCDIR]) dnl
-+ $PKGCONFIG --cflags-only-I rustls 2>/dev/null`
-+
-+ AC_SUBST(SSL_LIBS)
-+ AC_MSG_NOTICE([pkg-config: SSL_LIBS: "$SSL_LIBS"])
-+ AC_MSG_NOTICE([pkg-config: SSL_LDFLAGS: "$SSL_LDFLAGS"])
-+ AC_MSG_NOTICE([pkg-config: SSL_CPPFLAGS: "$SSL_CPPFLAGS"])
-+
-+ LIB_RUSTLS=`echo $SSL_LDFLAGS | sed -e 's/^-L//'`
-+
-+ dnl use the values pkg-config reported. This is here
-+ dnl instead of below with CPPFLAGS and LDFLAGS because we only
-+ dnl learn about this via pkg-config. If we only have
-+ dnl the argument to --with-rustls we don't know what
-+ dnl additional libs may be necessary. Hope that we
-+ dnl don't need any.
-+ LIBS="$SSL_LIBS $LIBS"
-+ USE_RUSTLS="yes"
-+ ssl_msg="rustls"
-+ AC_DEFINE(USE_RUSTLS, 1, [if rustls is enabled])
-+ AC_SUBST(USE_RUSTLS, [1])
-+ USE_RUSTLS="yes"
-+ RUSTLS_ENABLED=1
-+ test rustls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
-+ else
-+ AC_MSG_ERROR([pkg-config: Could not find rustls])
- fi
-
-- fi dnl rustls not disabled
-+ else
-+ dnl we did not use pkg-config, so we need to add the
-+ dnl rustls lib to LIBS
-+ LIBS="-lrustls -lpthread -ldl -lm $LIBS"
-+ fi
-+
-+ dnl finally, set flags to use this TLS backend
-+ CPPFLAGS="$CLEAN_CPPFLAGS $SSL_CPPFLAGS"
-+ LDFLAGS="$CLAN_LDFLAGS $SSL_LDFLAGS"
-+
-+ if test "x$USE_RUSTLS" = "xyes"; then
-+ AC_MSG_NOTICE([detected rustls])
-+ check_for_ca_bundle=1
-+
-+ if test -n "$LIB_RUSTLS"; then
-+ dnl when shared libs were found in a path that the run-time
-+ dnl linker does not search through, we need to add it to
-+ dnl CURL_LIBRARY_PATH so that further configure tests do not
-+ dnl fail due to this
-+ if test "x$cross_compiling" != "xyes"; then
-+ CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$LIB_RUSTLS"
-+ export CURL_LIBRARY_PATH
-+ AC_MSG_NOTICE([Added $LIB_RUSTLS to CURL_LIBRARY_PATH])
-+ fi
-+ fi
-+ fi
-
- test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
-+
-+ if test X"$OPT_RUSTLS" != Xno &&
-+ test "$RUSTLS_ENABLED" != "1"; then
-+ AC_MSG_NOTICE([OPT_RUSTLS: $OPT_RUSTLS])
-+ AC_MSG_NOTICE([RUSTLS_ENABLED: $RUSTLS_ENABLED])
-+ AC_MSG_ERROR([--with-rustls was given but Rustls could not be detected])
-+ fi
- fi
- ])
-+
-+
-+RUSTLS_ENABLED
---
-2.44.0
-
diff --git a/net-misc/curl/files/curl-8.6.0-vtls-revert-receive-max-buffer-add-test-case.patch b/net-misc/curl/files/curl-8.6.0-vtls-revert-receive-max-buffer-add-test-case.patch
deleted file mode 100644
index 66e8399370a2..000000000000
--- a/net-misc/curl/files/curl-8.6.0-vtls-revert-receive-max-buffer-add-test-case.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-https://bugs.gentoo.org/924017
-https://github.com/curl/curl/pull/12848
-
-From ed09a99af57200643d5ae001e815eeab9ffe3f84 Mon Sep 17 00:00:00 2001
-From: Stefan Eissing <stefan@eissing.org>
-Date: Thu, 1 Feb 2024 18:15:50 +0100
-Subject: [PATCH] vtls: revert "receive max buffer" + add test case
-
-- add test_05_04 for requests using http/1.0, http/1.1 and h2 against an
- Apache resource that does an unclean TLS shutdown.
-- revert special workarund in openssl.c for suppressing shutdown errors
- on multiplexed connections
-- vlts.c restore to its state before 9a90c9dd64d2f03601833a70786d485851bd1b53
-
-Fixes #12885
-Fixes #12844
-
-Closes #12848
----
- lib/vtls/vtls.c | 27 ++++++---------------------
- 1 file changed, 6 insertions(+), 21 deletions(-)
-
-diff --git a/lib/vtls/vtls.c b/lib/vtls/vtls.c
-index e928ba5d0..f654a9749 100644
---- a/lib/vtls/vtls.c
-+++ b/lib/vtls/vtls.c
-@@ -1715,32 +1715,17 @@ static ssize_t ssl_cf_recv(struct Curl_cfilter *cf,
- {
- struct cf_call_data save;
- ssize_t nread;
-- size_t ntotal = 0;
-
- CF_DATA_SAVE(save, cf, data);
- *err = CURLE_OK;
-- /* Do receive until we fill the buffer somehwhat or EGAIN, error or EOF */
-- while(!ntotal || (len - ntotal) > (4*1024)) {
-+ nread = Curl_ssl->recv_plain(cf, data, buf, len, err);
-+ if(nread > 0) {
-+ DEBUGASSERT((size_t)nread <= len);
-+ }
-+ else if(nread == 0) {
-+ /* eof */
- *err = CURLE_OK;
-- nread = Curl_ssl->recv_plain(cf, data, buf + ntotal, len - ntotal, err);
-- if(nread < 0) {
-- if(*err == CURLE_AGAIN && ntotal > 0) {
-- /* we EAGAINed after having reed data, return the success amount */
-- *err = CURLE_OK;
-- break;
-- }
-- /* we have a an error to report */
-- goto out;
-- }
-- else if(nread == 0) {
-- /* eof */
-- break;
-- }
-- ntotal += (size_t)nread;
-- DEBUGASSERT((size_t)ntotal <= len);
- }
-- nread = (ssize_t)ntotal;
--out:
- CURL_TRC_CF(data, cf, "cf_recv(len=%zu) -> %zd, %d", len,
- nread, *err);
- CF_DATA_RESTORE(cf, save);
---
-2.43.0
-
diff --git a/net-misc/curl/files/curl-8.8.0-install-manpage.patch b/net-misc/curl/files/curl-8.8.0-install-manpage.patch
new file mode 100644
index 000000000000..f58ddae1c302
--- /dev/null
+++ b/net-misc/curl/files/curl-8.8.0-install-manpage.patch
@@ -0,0 +1,22 @@
+https://patch-diff.githubusercontent.com/raw/curl/curl/pull/13741
+From: Daniel Stenberg <daniel@haxx.se>
+Date: Wed, 22 May 2024 08:43:43 +0200
+Subject: [PATCH] docs/Makefile.am: make curl-config.1 install
+
+on "make install" like it should
+---
+ docs/Makefile.am | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/docs/Makefile.am b/docs/Makefile.am
+index 83f5b0c461cc0f..e9ef6284860555 100644
+--- a/docs/Makefile.am
++++ b/docs/Makefile.am
+@@ -28,6 +28,7 @@ if BUILD_DOCS
+ # if we disable man page building, ignore these
+ MK_CA_DOCS = mk-ca-bundle.1
+ CURLCONF_DOCS = curl-config.1
++man_MANS = curl-config.1
+ endif
+
+ CURLPAGES = curl-config.md mk-ca-bundle.md
diff --git a/net-misc/curl/files/curl-8.8.0-mbedtls.patch b/net-misc/curl/files/curl-8.8.0-mbedtls.patch
new file mode 100644
index 000000000000..8fa4d6ef7cfe
--- /dev/null
+++ b/net-misc/curl/files/curl-8.8.0-mbedtls.patch
@@ -0,0 +1,42 @@
+https://github.com/curl/curl/pull/13749
+From: Stefan Eissing <stefan@eissing.org>
+Date: Wed, 22 May 2024 14:44:56 +0200
+Subject: [PATCH] mbedtls, check version for cipher id
+
+- mbedtls_ssl_get_ciphersuite_id_from_ssl() seems to have
+ been added in mbedtls 3.2.0. Check for that version.
+--- a/lib/vtls/mbedtls.c
++++ b/lib/vtls/mbedtls.c
+@@ -902,8 +902,6 @@ mbed_connect_step2(struct Curl_cfilter *cf, struct Curl_easy *data)
+ (struct mbed_ssl_backend_data *)connssl->backend;
+ struct ssl_primary_config *conn_config = Curl_ssl_cf_get_primary_config(cf);
+ const mbedtls_x509_crt *peercert;
+- char cipher_str[64];
+- uint16_t cipher_id;
+ #ifndef CURL_DISABLE_PROXY
+ const char * const pinnedpubkey = Curl_ssl_cf_is_proxy(cf)?
+ data->set.str[STRING_SSL_PINNEDPUBLICKEY_PROXY]:
+@@ -932,11 +930,18 @@ mbed_connect_step2(struct Curl_cfilter *cf, struct Curl_easy *data)
+ return CURLE_SSL_CONNECT_ERROR;
+ }
+
+- cipher_id = (uint16_t)
+- mbedtls_ssl_get_ciphersuite_id_from_ssl(&backend->ssl);
+- mbed_cipher_suite_get_str(cipher_id, cipher_str, sizeof(cipher_str), true);
+- infof(data, "mbedTLS: Handshake complete, cipher is %s", cipher_str);
+-
++#if MBEDTLS_VERSION_NUMBER >= 0x03020000
++ {
++ char cipher_str[64];
++ uint16_t cipher_id;
++ cipher_id = (uint16_t)
++ mbedtls_ssl_get_ciphersuite_id_from_ssl(&backend->ssl);
++ mbed_cipher_suite_get_str(cipher_id, cipher_str, sizeof(cipher_str), true);
++ infof(data, "mbedTLS: Handshake complete, cipher is %s", cipher_str);
++ }
++#else
++ infof(data, "mbedTLS: Handshake complete");
++#endif
+ ret = mbedtls_ssl_get_verify_result(&backend->ssl);
+
+ if(!conn_config->verifyhost)
diff --git a/net-misc/curl/files/curl-prefix-2.patch b/net-misc/curl/files/curl-prefix-2.patch
new file mode 100644
index 000000000000..0372038e7d59
--- /dev/null
+++ b/net-misc/curl/files/curl-prefix-2.patch
@@ -0,0 +1,34 @@
+From a3033ee39f2cc43cb17386b23cb304b010c2c96f Mon Sep 17 00:00:00 2001
+From: Matt Jolly <Matt.Jolly@footclan.ninja>
+Date: Wed, 22 May 2024 16:18:51 +1000
+Subject: [PATCH] Update prefix patch for 8.8.0
+
+---
+ curl-config.in | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/curl-config.in b/curl-config.in
+index 085bb1e..c0bc6ce 100644
+--- a/curl-config.in
++++ b/curl-config.in
+@@ -145,7 +145,7 @@ while test "$#" -gt 0; do
+ else
+ CPPFLAG_CURL_STATICLIB=""
+ fi
+- if test "X@includedir@" = "X/usr/include"; then
++ if test "X@includedir@" = "X@GENTOO_PORTAGE_EPREFIX@/usr/include"; then
+ echo "${CPPFLAG_CURL_STATICLIB}"
+ else
+ echo "${CPPFLAG_CURL_STATICLIB}-I@includedir@"
+@@ -153,7 +153,7 @@ while test "$#" -gt 0; do
+ ;;
+
+ --libs)
+- if test "X@libdir@" != "X/usr/lib" -a "X@libdir@" != "X/usr/lib64"; then
++ if test "X@libdir@" != "X@GENTOO_PORTAGE_EPREFIX@/usr/lib" -a "X@libdir@" != "X@GENTOO_PORTAGE_EPREFIX@/usr/lib64"; then
+ CURLLIBDIR="-L@libdir@ "
+ else
+ CURLLIBDIR=""
+--
+2.45.0
+