lighttpd: Fix Compilation with OpenSSL 1.1.x
authorRosen Penev <rosenp@gmail.com>
Sat, 10 Nov 2018 02:53:32 +0000 (18:53 -0800)
committerRosen Penev <rosenp@gmail.com>
Sat, 10 Nov 2018 02:53:32 +0000 (18:53 -0800)
Signed-off-by: Rosen Penev <rosenp@gmail.com>
net/lighttpd/Makefile
net/lighttpd/patches/010-openssl-deprecated.patch [new file with mode: 0644]

index cb0ab7d7fcd84297c03dd8945c4d9b3e43c6214e..afe7a4a78aa3288aa27126329917be1bcd0f8f23 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=lighttpd
 PKG_VERSION:=1.4.49
-PKG_RELEASE:=2
+PKG_RELEASE:=3
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=https://download.lighttpd.net/lighttpd/releases-1.4.x
diff --git a/net/lighttpd/patches/010-openssl-deprecated.patch b/net/lighttpd/patches/010-openssl-deprecated.patch
new file mode 100644 (file)
index 0000000..0b2176b
--- /dev/null
@@ -0,0 +1,14 @@
+diff --git a/src/rand.c b/src/rand.c
+index 10cd025..63fbb0d 100644
+--- a/src/rand.c
++++ b/src/rand.c
+@@ -226,7 +226,9 @@ int li_rand_bytes (unsigned char *buf, int num)
+ void li_rand_cleanup (void)
+ {
+   #ifdef USE_OPENSSL_CRYPTO
++  #if OPENSSL_VERSION_NUMBER < 0x10100000L
+     RAND_cleanup();
++  #endif
+   #endif
+     safe_memclear(xsubi, sizeof(xsubi));
+ }