Version 5.4.3.2, tag libreoffice-5.4.3.2
[LibreOffice.git] / xmlsecurity / Library_xsec_xmlsec.mk
blob5c3e20a9b970a18f7999c4b438ff386e76324b70
1 # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 $(eval $(call gb_Library_Library,xsec_xmlsec))
12 ifeq ($(OS),WNT)
13 $(eval $(call gb_Library_set_componentfile,xsec_xmlsec,xmlsecurity/util/xsec_xmlsec.windows))
14 else
15 $(eval $(call gb_Library_set_componentfile,xsec_xmlsec,xmlsecurity/util/xsec_xmlsec))
16 endif
18 $(eval $(call gb_Library_set_include,xsec_xmlsec,\
19 $$(INCLUDE) \
20 -I$(SRCDIR)/xmlsecurity/inc \
21 -I$(SRCDIR)/xmlsecurity/source/gpg \
22 -I$(SRCDIR)/xmlsecurity/source/xmlsec \
23 -I$(call gb_UnpackedTarball_get_dir,xmlsec/include) \
26 $(eval $(call gb_Library_use_custom_headers,xsec_xmlsec,\
27 officecfg/registry \
30 $(eval $(call gb_Library_use_sdk_api,xsec_xmlsec))
32 $(eval $(call gb_Library_add_defs,xsec_xmlsec,\
33 -DXMLSEC_NO_XSLT \
34 -DXSECXMLSEC_DLLIMPLEMENTATION \
37 $(eval $(call gb_Library_set_precompiled_header,xsec_xmlsec,$(SRCDIR)/xmlsecurity/inc/pch/precompiled_xsec_xmlsec))
39 $(eval $(call gb_Library_use_libraries,xsec_xmlsec,\
40 comphelper \
41 cppu \
42 cppuhelper \
43 sal \
44 svl \
45 tl \
46 xo \
49 ifeq ($(SYSTEM_XMLSEC),)
50 $(eval $(call gb_Library_use_packages,xsec_xmlsec,\
51 xmlsec \
53 endif
55 $(eval $(call gb_Library_use_externals,xsec_xmlsec,\
56 boost_headers \
57 libxml2 \
58 xmlsec \
59 nss3 \
61 ifneq ($(filter-out WNT MACOSX ANDROID IOS,$(OS)),)
62 $(eval $(call gb_Library_use_externals,xsec_xmlsec,\
63 gpgmepp \
65 endif
67 $(eval $(call gb_Library_add_exception_objects,xsec_xmlsec,\
68 xmlsecurity/source/xmlsec/biginteger \
69 xmlsecurity/source/xmlsec/certificateextension_certextn \
70 xmlsecurity/source/xmlsec/errorcallback \
71 xmlsecurity/source/xmlsec/saxhelper \
72 xmlsecurity/source/xmlsec/serialnumberadapter \
73 xmlsecurity/source/xmlsec/xmldocumentwrapper_xmlsecimpl \
74 xmlsecurity/source/xmlsec/xmlelementwrapper_xmlsecimpl \
75 xmlsecurity/source/xmlsec/xmlsec_init \
76 xmlsecurity/source/xmlsec/xmlstreamio \
77 xmlsecurity/source/xmlsec/xsec_xmlsec \
78 xmlsecurity/source/xmlsec/nss/ciphercontext \
79 xmlsecurity/source/xmlsec/nss/digestcontext \
80 xmlsecurity/source/xmlsec/nss/nssinitializer \
81 xmlsecurity/source/xmlsec/nss/xsec_nss \
84 ifneq ($(filter-out WNT MACOSX ANDROID IOS,$(OS)),)
85 $(eval $(call gb_Library_add_exception_objects,xsec_xmlsec,\
86 xmlsecurity/source/gpg/CertificateImpl \
87 xmlsecurity/source/gpg/CipherContext \
88 xmlsecurity/source/gpg/DigestContext \
89 xmlsecurity/source/gpg/SecurityEnvironment \
90 xmlsecurity/source/gpg/SEInitializer \
91 xmlsecurity/source/gpg/XMLEncryption \
92 xmlsecurity/source/gpg/XMLSecurityContext \
93 xmlsecurity/source/gpg/xmlsignature_gpgimpl \
95 endif
97 ifeq ($(OS),WNT)
99 $(eval $(call gb_Library_add_defs,xsec_xmlsec,\
100 -DXMLSEC_CRYPTO_MSCRYPTO \
104 $(eval $(call gb_Library_add_libs,xsec_xmlsec,\
105 $(call gb_UnpackedTarball_get_dir,xmlsec)/win32/binaries/libxmlsec-mscrypto.lib \
106 $(call gb_UnpackedTarball_get_dir,xmlsec)/win32/binaries/libxmlsec.lib \
109 $(eval $(call gb_Library_use_system_win32_libs,xsec_xmlsec,\
110 crypt32 \
111 advapi32 \
114 $(eval $(call gb_Library_add_exception_objects,xsec_xmlsec,\
115 xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl \
116 xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl \
117 xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl \
118 xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl \
119 xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl \
120 xmlsecurity/source/xmlsec/mscrypt/xmlsecuritycontext_mscryptimpl \
121 xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl \
122 xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt \
125 else
127 $(eval $(call gb_Library_add_defs,xsec_xmlsec,\
128 -DXMLSEC_CRYPTO_NSS \
131 ifeq ($(OS),ANDROID)
132 $(eval $(call gb_Library_add_libs,xsec_xmlsec,\
133 $(call gb_UnpackedTarball_get_dir,xmlsec)/src/openssl/.libs/libxmlsec1-openssl.a \
134 $(call gb_UnpackedTarball_get_dir,xmlsec)/src/.libs/libxmlsec1.a \
136 else
138 ifeq ($(SYSTEM_XMLSEC),)
139 $(eval $(call gb_Library_add_libs,xsec_xmlsec,\
140 $(call gb_UnpackedTarball_get_dir,xmlsec)/src/nss/.libs/libxmlsec1-nss.a \
141 $(call gb_UnpackedTarball_get_dir,xmlsec)/src/.libs/libxmlsec1.a \
143 endif
145 endif
147 $(eval $(call gb_Library_use_externals,xsec_xmlsec,\
148 plc4 \
151 $(eval $(call gb_Library_add_exception_objects,xsec_xmlsec,\
152 xmlsecurity/source/xmlsec/nss/sanextension_nssimpl \
153 xmlsecurity/source/xmlsec/nss/secerror \
154 xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl \
155 xmlsecurity/source/xmlsec/nss/seinitializer_nssimpl \
156 xmlsecurity/source/xmlsec/nss/x509certificate_nssimpl \
157 xmlsecurity/source/xmlsec/nss/xmlencryption_nssimpl \
158 xmlsecurity/source/xmlsec/nss/xmlsecuritycontext_nssimpl \
159 xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl \
162 endif
164 ifeq ($(OS),SOLARIS)
165 $(eval $(call gb_Library_add_libs,xsec_xmlsec,\
166 -ldl \
168 endif
170 # vim: set noet sw=4 ts=4: