xref: /aoo42x/main/xmlsecurity/util/makefile.mk (revision cdf0e10c)
1#*************************************************************************
2#
3# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4#
5# Copyright 2000, 2010 Oracle and/or its affiliates.
6#
7# OpenOffice.org - a multi-platform office productivity suite
8#
9# This file is part of OpenOffice.org.
10#
11# OpenOffice.org is free software: you can redistribute it and/or modify
12# it under the terms of the GNU Lesser General Public License version 3
13# only, as published by the Free Software Foundation.
14#
15# OpenOffice.org is distributed in the hope that it will be useful,
16# but WITHOUT ANY WARRANTY; without even the implied warranty of
17# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18# GNU Lesser General Public License version 3 for more details
19# (a copy is included in the LICENSE file that accompanied this code).
20#
21# You should have received a copy of the GNU Lesser General Public License
22# version 3 along with OpenOffice.org.  If not, see
23# <http://www.openoffice.org/license.html>
24# for a copy of the LGPLv3 License.
25#
26#*************************************************************************
27
28PRJ=..
29
30PRJNAME=xmlsecurity
31TARGET=xmlsecurity
32
33# Disable '-z defs' due to broken libxpcom.
34#LINKFLAGSDEFS=$(0)
35USE_DEFFILE=TRUE
36
37# --- Settings -----------------------------------------------------
38
39.INCLUDE :  settings.mk
40.INCLUDE :	$(PRJ)$/util$/target.pmk
41
42.IF "$(WITH_MOZILLA)" == "NO"
43@all:
44	@echo "No mozilla -> no nss -> no libxmlsec -> no xmlsecurity..."
45.ENDIF
46
47# --- Files --------------------------------------------------------
48
49BMP_IN=$(PRJ)$/res
50
51# --- Shared-Library -----------------------------------------------
52
53#
54# The 1st shared library
55#
56SHL1NAME=xsec_fw
57SHL1TARGET= $(SHL1NAME)
58SHL1LIBS= $(SLB)$/fw.lib
59
60SHL1STDLIBS +=		\
61	$(SALLIB)		\
62	$(CPPULIB)		\
63	$(CPPUHELPERLIB)
64
65SHL1IMPLIB = $(SHL1TARGET)
66SHL1DEF = $(MISC)$/$(SHL1TARGET).def
67DEF1NAME = $(SHL1TARGET)
68DEF1EXPORTFILE = xsec_fw.dxp
69
70#
71# The 2nd shared library
72#
73
74SHL2NAME=xsec_xmlsec
75SHL2TARGET= $(SHL2NAME)
76
77
78.IF "$(ENABLE_NSS_MODULE)"=="YES" || "$(SYSTEM_MOZILLA)" == "YES"
79
80SHL2LIBS= \
81	$(SLB)$/xs_comm.lib
82
83.IF "$(CRYPTO_ENGINE)" == "mscrypto"
84SHL2LIBS += \
85	$(SLB)$/xs_mscrypt.lib
86.ENDIF
87
88SHL2LIBS += \
89	$(SLB)$/xs_nss.lib
90
91.ENDIF
92
93
94SHL2STDLIBS +=			\
95	$(SALLIB)			\
96	$(CPPULIB)			\
97	$(CPPUHELPERLIB)	\
98	$(SALLIB)	\
99	$(SVLLIB)			\
100	$(TOOLSLIB)			\
101	$(COMPHELPERLIB)	\
102	$(CPPUHELPERLIB)	\
103	$(XMLOFFLIB)
104
105.IF "$(OS)"=="SOLARIS"
106SHL2STDLIBS +=-ldl
107.ENDIF
108
109.IF "$(SYSTEM_MOZILLA)" == "YES"
110.IF "$(NSPR_LIB)" != ""
111SHL2STDLIBS += $(NSPR_LIB)
112.ENDIF
113.IF "$(NSS_LIB)" != ""
114SHL2STDLIBS += $(NSS_LIB)
115.ENDIF
116.ENDIF
117
118.IF "$(CRYPTO_ENGINE)" == "mscrypto"
119SHL2STDLIBS+= $(MSCRYPTOLIBS)
120# SHL2STDLIBS+= $(XMLSECLIB) $(LIBXML2LIB) $(NSS3LIB) $(NSPR4LIB) $(PLC4LIB)
121SHL2STDLIBS+= $(NSS3LIB) $(NSPR4LIB)
122.ELSE
123SHL2STDLIBS+= $(NSSCRYPTOLIBS)
124.ENDIF
125
126
127SHL2IMPLIB = $(SHL2TARGET)
128SHL2DEF = $(MISC)$/$(SHL2TARGET).def
129DEF2NAME = $(SHL2TARGET)
130.IF "$(CRYPTO_ENGINE)" == "mscrypto"
131DEF2EXPORTFILE = exports_xsmscrypt.dxp
132.ENDIF
133
134DEF2EXPORTFILE = exports_xsnss.dxp
135
136SRSFILELIST=	\
137                $(SRS)$/component.srs   \
138                $(SRS)$/dialogs.srs
139
140RESLIB1NAME=xmlsec
141RESLIB1IMAGES=$(PRJ)$/res
142RESLIB1SRSFILES= $(SRSFILELIST)
143
144SHL4TARGET=$(TARGET)
145SHL4LIBS=\
146                $(SLB)$/helper.lib      \
147                $(SLB)$/dialogs.lib     \
148                $(SLB)$/component.lib
149
150SHL4STDLIBS=\
151                $(CPPULIB)			\
152				$(CPPUHELPERLIB)	\
153				$(COMPHELPERLIB)	\
154				$(UCBHELPERLIB)	    \
155				$(UNOTOOLSLIB)	    \
156				$(VCLLIB)			\
157				$(TOOLSLIB) 		\
158				$(SVTOOLLIB) 		\
159				$(SALLIB)			\
160				$(SVLLIB)			\
161				$(XMLOFFLIB)		\
162				$(SVXCORELIB)
163
164SHL4VERSIONMAP = $(SOLARENV)/src/component.map
165SHL4DEPN=
166SHL4IMPLIB=i$(TARGET)
167SHL4DEF=$(MISC)$/$(SHL4TARGET).def
168DEF4NAME=$(SHL4TARGET)
169
170# --- Targets ----------------------------------------------------------
171
172.INCLUDE :  target.mk
173
174# --- Filter -----------------------------------------------------------
175
176$(MISC)$/$(SHL3TARGET).flt: makefile.mk
177	$(TYPE) $(SHL3TARGET).flt > $@
178
179ALLTAR : \
180    $(MISC)/xmlsecurity.component \
181    $(MISC)/xsec_fw.component \
182    $(MISC)/xsec_xmlsec.component
183
184.IF "$(OS)" == "WNT"
185my_platform = .windows
186.END
187
188$(MISC)/xmlsecurity.component .ERRREMOVE : \
189        $(SOLARENV)/bin/createcomponent.xslt xmlsecurity.component
190    $(XSLTPROC) --nonet --stringparam uri \
191        '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL4TARGETN:f)' -o $@ \
192        $(SOLARENV)/bin/createcomponent.xslt xmlsecurity.component
193
194$(MISC)/xsec_fw.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
195        xsec_fw.component
196    $(XSLTPROC) --nonet --stringparam uri \
197        '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
198        $(SOLARENV)/bin/createcomponent.xslt xsec_fw.component
199
200$(MISC)/xsec_xmlsec.component .ERRREMOVE : \
201        $(SOLARENV)/bin/createcomponent.xslt xsec_xmlsec.component
202    $(XSLTPROC) --nonet --stringparam uri \
203        '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL2TARGETN:f)' -o $@ \
204        $(SOLARENV)/bin/createcomponent.xslt xsec_xmlsec$(my_platform).component
205