From 8c77bcc19f4283813cdbb99842bb1c330fadf124 Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Thu, 27 Jun 2019 00:28:25 -0700 Subject: [PATCH] domoticz: Fix compilation without deprecated OpenSSL APIs Signed-off-by: Rosen Penev --- utils/domoticz/Makefile | 2 +- .../patches/020-openssl-deprecated.patch | 24 +++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 utils/domoticz/patches/020-openssl-deprecated.patch diff --git a/utils/domoticz/Makefile b/utils/domoticz/Makefile index 7bd2ae06b..23a819768 100644 --- a/utils/domoticz/Makefile +++ b/utils/domoticz/Makefile @@ -12,7 +12,7 @@ PKG_VERSION_MAJOR:=4 PKG_VERSION_PATCH:=9700 PKG_COMMIT:= PKG_VERSION:=$(PKG_VERSION_MAJOR).$(PKG_VERSION_PATCH) -PKG_RELEASE:=3 +PKG_RELEASE:=4 ifeq ($(PKG_COMMIT),) PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz diff --git a/utils/domoticz/patches/020-openssl-deprecated.patch b/utils/domoticz/patches/020-openssl-deprecated.patch new file mode 100644 index 000000000..94ca26c26 --- /dev/null +++ b/utils/domoticz/patches/020-openssl-deprecated.patch @@ -0,0 +1,24 @@ +From 87749eb9b74d82dced807cc16fb011d4e3fb052d Mon Sep 17 00:00:00 2001 +From: Rosen Penev +Date: Sat, 13 Jul 2019 17:28:06 -0700 +Subject: [PATCH] WebServerHelper: Fix compilation - deprecated APIs + +OpenSSL has initialization deprecated. +--- + main/WebServerHelper.cpp | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/main/WebServerHelper.cpp b/main/WebServerHelper.cpp +index 98ebcf7b4..0a028595c 100644 +--- a/main/WebServerHelper.cpp ++++ b/main/WebServerHelper.cpp +@@ -37,7 +37,9 @@ namespace http { + our_listener_port = web_settings.listening_port; + #ifdef WWW_ENABLE_SSL + if (secure_web_settings.is_enabled()) { ++#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined(LIBRESSL_VERSION_NUMBER) + SSL_library_init(); ++#endif + secureServer_.reset(new CWebServer()); + bRet |= secureServer_->StartServer(secure_web_settings, serverpath, bIgnoreUsernamePassword); + serverCollection.push_back(secureServer_);