git: Fix compilation without deprecated OpenSSL APIs
authorRosen Penev <rosenp@gmail.com>
Thu, 13 Dec 2018 22:39:55 +0000 (14:39 -0800)
committertripolar <tripolar@users.noreply.github.com>
Sun, 17 Feb 2019 23:29:15 +0000 (00:29 +0100)
Signed-off-by: Rosen Penev <rosenp@gmail.com>
net/git/Makefile
net/git/patches/300-openssl-deprecated.patch [new file with mode: 0644]

index 3b8017948be4138a2e902251a4d357ff005b43a7..f6257b9d21fd7b3c7f3c6ee46e7ccf82011f004f 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=git
 PKG_VERSION:=2.20.1
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=@KERNEL/software/scm/git/
diff --git a/net/git/patches/300-openssl-deprecated.patch b/net/git/patches/300-openssl-deprecated.patch
new file mode 100644 (file)
index 0000000..e3a9ad8
--- /dev/null
@@ -0,0 +1,32 @@
+From fa37195d8378ac958d1f9bd884b47bd73730040e Mon Sep 17 00:00:00 2001
+From: Rosen Penev <rosenp@gmail.com>
+Date: Thu, 27 Dec 2018 09:58:07 -0800
+Subject: [PATCH] imap-send: Fix compilation without deprecated OpenSSL APIs
+
+Initialization in OpenSSL has been deprecated in version 1.1. This makes
+compilation fail when deprecated APIs for OpenSSL are compile-time
+disabled.
+
+Signed-off-by: Rosen Penev <rosenp@gmail.com>
+---
+ imap-send.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/imap-send.c b/imap-send.c
+index b4eb886e2..877a4e368 100644
+--- a/imap-send.c
++++ b/imap-send.c
+@@ -284,8 +284,10 @@ static int ssl_socket_connect(struct imap_socket *sock, int use_tls_only, int ve
+       int ret;
+       X509 *cert;
++#if (OPENSSL_VERSION_NUMBER < 0x10100000L)
+       SSL_library_init();
+       SSL_load_error_strings();
++#endif
+       meth = SSLv23_method();
+       if (!meth) {
+-- 
+2.20.1
+