aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Grosbein <eugen@FreeBSD.org>2023-06-10 11:01:46 +0000
committerEugene Grosbein <eugen@FreeBSD.org>2023-06-10 11:01:46 +0000
commitcaed0bd84c824ef31eea79fc50853a2800b03de5 (patch)
treed7fe95906863f74269d4eaddbf1fce21fed82c3e
parent637c0bace26138529a36232e948549ad59342ba9 (diff)
downloadports-caed0bd84c824ef31eea79fc50853a2800b03de5.tar.gz
ports-caed0bd84c824ef31eea79fc50853a2800b03de5.zip
net/mpd5: unbreak build with OpenSSL 3.0
This fixes build, so PORTREVISION not bumped.
-rw-r--r--net/mpd5/files/patch-openssl3041
1 files changed, 41 insertions, 0 deletions
diff --git a/net/mpd5/files/patch-openssl30 b/net/mpd5/files/patch-openssl30
new file mode 100644
index 000000000000..9aebcd6dd547
--- /dev/null
+++ b/net/mpd5/files/patch-openssl30
@@ -0,0 +1,41 @@
+Index: src/contrib/libpdel/io/ssl_fp.c
+===================================================================
+--- src/contrib/libpdel/io/ssl_fp.c (revision 2544)
++++ src/contrib/libpdel/io/ssl_fp.c (revision 2546)
+@@ -53,6 +53,7 @@
+
+ #include <openssl/ssl.h>
+ #include <openssl/err.h>
++#include <openssl/opensslv.h>
+
+ #include "structs/structs.h"
+ #include "structs/type/array.h"
+@@ -364,6 +365,7 @@ ssl_log(ssl_logger_t *logger, void *logarg)
+ }
+ #endif
+
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x30000000L
+ /* Add function */
+ if ((t = ERR_func_error_string(e)) != NULL) {
+ strlcat(buf, t, sizeof(buf));
+@@ -372,6 +374,7 @@ ssl_log(ssl_logger_t *logger, void *logarg)
+ snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
+ "func=%u: ", ERR_GET_FUNC(e));
+ }
++#endif
+
+ /* Add reason */
+ if ((t = ERR_reason_error_string(e)) != NULL) {
+Index: src/Makefile
+===================================================================
+--- src/Makefile (revision 2544)
++++ src/Makefile (revision 2546)
+@@ -147,6 +147,8 @@ CFLAGS+= -DMPD_VENDOR='"${MPD_VENDOR}"'
+ CFLAGS+= -DSYSLOG_FACILITY='"${SYSLOG_FACILITY}"'
+ .endif
+
++CFLAGS+= -DOPENSSL_API_COMPAT=10100
++
+ # Standard sources
+
+ STDSRCS= assert.c auth.c bund.c rep.c ccp.c chap.c \