diff --git a/Repository.mk b/Repository.mk index 6cbdc2fc5760..87253d01149a 100644 --- a/Repository.mk +++ b/Repository.mk @@ -153,9 +153,6 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ fileacc \ mcnttype \ neon \ - nspr4 \ - nss3 \ - plc4 \ test \ xmlsecurity \ xsec_fw \ diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk index c0c97050add4..ed87327feb1b 100644 --- a/RepositoryExternal.mk +++ b/RepositoryExternal.mk @@ -658,4 +658,33 @@ $(call gb_LinkTarget_add_libs,$(1), \ endef +ifeq ($(SYSTEM_MOZILLA),YES) + +define gb_LinkTarget__use_plc4 +$(call gb_LinkTarget_set_include,$(1),\ + $$(INCLUDE) \ + $(MOZ_NSS_CFLAGS) \ +) + +$(call gb_LinkTarget_add_libs,$(1),\ + $(MOZ_NSS_LIBS) \ +) +endef + +else + +define gb_LinkTarget__use_plc4 +$(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ + nspr4 \ + nss3 \ + plc4 \ +)) + +$(call gb_LinkTarget_add_linked_libs,$(1),\ + plc4 \ +) +endef + +endif + # vim: set noet sw=4 ts=4: diff --git a/xmlsecurity/Library_xsec_xmlsec.mk b/xmlsecurity/Library_xsec_xmlsec.mk index 770122ec2586..15a22167119e 100644 --- a/xmlsecurity/Library_xsec_xmlsec.mk +++ b/xmlsecurity/Library_xsec_xmlsec.mk @@ -124,7 +124,7 @@ $(eval $(call gb_Library_add_linked_static_libs,xsec_xmlsec,\ xmlsec1-nss \ )) -$(eval $(call gb_Library_add_linked_libs,xsec_xmlsec,\ +$(eval $(call gb_Library_use_externals,xsec_xmlsec,\ plc4 \ ))