[PATCH] package: openssl: Enable built engines per default

Daniel Danzberger daniel at dd-wrt.com
Thu Apr 22 07:54:29 BST 2021

Automatically enable an engine in the openssl.cnf if it has been build.
Before this change, /etc/openssl.cnf had to be edited manually on the
system to enable the engine.

Signed-off-by: Daniel Danzberger <daniel at dd-wrt.com>
 package/libs/openssl/Makefile | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/package/libs/openssl/Makefile b/package/libs/openssl/Makefile
index 7ab4c6ccd0..d101ee3aa2 100644
--- a/package/libs/openssl/Makefile
+++ b/package/libs/openssl/Makefile
@@ -375,9 +375,16 @@ define Package/libopenssl/install
+define Package/libopenssl-conf/enable
+	$(if $(CONFIG_PACKAGE_libopenssl-$(2)),sed -i s/^\#*$(2)=$(2)/$(2)=$(2)/ $(1)/etc/ssl/openssl.cnf)
 define Package/libopenssl-conf/install
 	$(INSTALL_DIR) $(1)/etc/ssl
 	$(CP) $(PKG_INSTALL_DIR)/etc/ssl/openssl.cnf $(1)/etc/ssl/
+	$(call Package/libopenssl-conf/enable,$(1),devcrypto)
+	$(call Package/libopenssl-conf/enable,$(1),afalg)
+	$(call Package/libopenssl-conf/enable,$(1),padlock)
 define Package/openssl-util/install

More information about the openwrt-devel mailing list