From 013ddc4f5307df512767ca23b3922540b2b36d52 Mon Sep 17 00:00:00 2001 From: Jan-Marek Glogowski <glogow@fbihome.de> Date: Fri, 23 Apr 2021 10:04:29 +0200 Subject: Switch OPENSSL config var from negative to positive - align with most of the rest of config_host - rename DISABLE_OPENSSL to ENABLE_OPENSSL - make this configurable Change-Id: Ic3b41fcdda38db66134939f12265e0da24833d60 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114564 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de> --- xmlsecurity/Module_xmlsecurity.mk | 8 +------- xmlsecurity/source/xmlsec/xmlsec_init.cxx | 12 ++++++++---- 2 files changed, 9 insertions(+), 11 deletions(-) (limited to 'xmlsecurity') diff --git a/xmlsecurity/Module_xmlsecurity.mk b/xmlsecurity/Module_xmlsecurity.mk index 81e74ecf21d3..2a6db1c4f74e 100644 --- a/xmlsecurity/Module_xmlsecurity.mk +++ b/xmlsecurity/Module_xmlsecurity.mk @@ -9,11 +9,9 @@ $(eval $(call gb_Module_Module,xmlsecurity)) -ifeq ($(ENABLE_NSS),TRUE) - $(eval $(call gb_Module_add_targets,xmlsecurity,\ Library_xmlsecurity \ - Library_xsec_xmlsec \ + $(if $(ENABLE_NSS)$(ENABLE_OPENSSL),Library_xsec_xmlsec) \ UIConfig_xmlsec \ )) @@ -40,13 +38,9 @@ $(eval $(call gb_Module_add_screenshot_targets,xmlsecurity,\ )) ifneq (,$(filter DESKTOP,$(BUILD_TYPE))) - $(eval $(call gb_Module_add_targets,xmlsecurity,\ Executable_pdfverify \ )) - -endif - endif # vim: set noet sw=4 ts=4: diff --git a/xmlsecurity/source/xmlsec/xmlsec_init.cxx b/xmlsecurity/source/xmlsec/xmlsec_init.cxx index 7e8c58ddeec3..410408ed2ebe 100644 --- a/xmlsecurity/source/xmlsec/xmlsec_init.cxx +++ b/xmlsecurity/source/xmlsec/xmlsec_init.cxx @@ -17,7 +17,8 @@ #include <xmlsec/xmlstreamio.hxx> #ifdef XMLSEC_CRYPTO_MSCRYPTO #include <xmlsec/mscng/crypto.h> -#else +#endif +#ifdef XMLSEC_CRYPTO_NSS #include <xmlsec/nss/crypto.h> #endif @@ -36,7 +37,8 @@ XSECXMLSEC_DLLPUBLIC void initXmlSec() xmlSecShutdown(); throw RuntimeException(); } -#else +#endif +#ifdef XMLSEC_CRYPTO_NSS if( xmlSecNssInit() < 0 ) { xmlSecShutdown(); throw RuntimeException(); @@ -47,7 +49,8 @@ XSECXMLSEC_DLLPUBLIC void initXmlSec() if( xmlEnableStreamInputCallbacks() < 0 ) { #ifdef XMLSEC_CRYPTO_MSCRYPTO xmlSecMSCngShutdown(); -#else +#endif +#ifdef XMLSEC_CRYPTO_NSS xmlSecNssShutdown(); #endif xmlSecShutdown() ; @@ -60,7 +63,8 @@ XSECXMLSEC_DLLPUBLIC void deInitXmlSec() xmlDisableStreamInputCallbacks(); #ifdef XMLSEC_CRYPTO_MSCRYPTO xmlSecMSCngShutdown(); -#else +#endif +#ifdef XMLSEC_CRYPTO_NSS xmlSecNssShutdown(); #endif xmlSecShutdown(); -- cgit