xref: /aoo41x/main/scp2/source/ooo/makefile.mk (revision 06f2ef55)
1#**************************************************************
2#
3#  Licensed to the Apache Software Foundation (ASF) under one
4#  or more contributor license agreements.  See the NOTICE file
5#  distributed with this work for additional information
6#  regarding copyright ownership.  The ASF licenses this file
7#  to you under the Apache License, Version 2.0 (the
8#  "License"); you may not use this file except in compliance
9#  with the License.  You may obtain a copy of the License at
10#
11#    http://www.apache.org/licenses/LICENSE-2.0
12#
13#  Unless required by applicable law or agreed to in writing,
14#  software distributed under the License is distributed on an
15#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16#  KIND, either express or implied.  See the License for the
17#  specific language governing permissions and limitations
18#  under the License.
19#
20#**************************************************************
21
22
23PRJ=..$/..
24
25PRJPCH=
26
27PRJNAME=scp2
28TARGET=ooo
29TARGETTYPE=CUI
30
31# --- Settings -----------------------------------------------------
32
33.INCLUDE :  settings.mk
34.INCLUDE :  i18npool/version.mk
35
36.IF "$(COM)" == "MSC"
37SCPDEFS+=-D_MSC
38.ENDIF
39
40.IF "$(BUILD_SPECIAL)"!=""
41SCPDEFS+=-DBUILD_SPECIAL
42.ENDIF
43
44.IF "$(BUILD_X64)"!=""
45SCPDEFS+=-DBUILD_X64
46.ENDIF
47
48.IF "$(PROF_EDITION)"!=""
49SCPDEFS+=-DPROF_EDITION
50.ENDIF
51
52.IF "$(GUI)"=="UNX"
53.IF "$(ENABLE_GTK)" != ""
54SCPDEFS+=-DENABLE_GTK
55PKGCONFIG_MODULES=gtk+-2.0
56.INCLUDE: pkg_config.mk
57GTK_TWO_FOUR=$(shell @+-$(PKG_CONFIG) --exists 'gtk+-2.0 >= 2.4.0' && echo YES)
58.IF "$(GTK_TWO_FOUR)" != ""
59SCPDEFS+=-DGTK_TWO_FOUR
60.ENDIF
61.ENDIF
62.ENDIF			# "$(GUI)"=="UNX"
63
64.IF "$(ENABLE_SYSTRAY_GTK)" != ""
65SCPDEFS+=-DENABLE_SYSTRAY_GTK
66.ENDIF
67
68.IF "$(ENABLE_GSTREAMER)" != ""
69SCPDEFS+=-DENABLE_GSTREAMER
70.ENDIF
71
72.IF "$(ENABLE_KDE)" != ""
73SCPDEFS+=-DENABLE_KDE
74.ENDIF
75
76.IF "$(ENABLE_KDE4)" != ""
77SCPDEFS+=-DENABLE_KDE4
78.ENDIF
79
80.IF "$(ENABLE_KAB)" != ""
81SCPDEFS+=-DENABLE_KAB
82.ENDIF
83
84.IF "$(ENABLE_EVOAB2)" != ""
85SCPDEFS+=-DENABLE_EVOAB2
86.ENDIF
87
88.IF "$(ENABLE_DIRECTX)" != ""
89SCPDEFS+=-DENABLE_DIRECTX
90.ENDIF
91
92.IF "$(SYSTEM_FREETYPE)" == "YES"
93SCPDEFS+=-DSYSTEM_FREETYPE
94.ENDIF
95
96.IF "$(SYSTEM_CAIRO)" == "YES"
97SCPDEFS+=-DSYSTEM_CAIRO
98.ENDIF
99
100.IF "$(ENABLE_CAIRO)" == "YES"
101SCPDEFS+=-DENABLE_CAIRO
102.ENDIF
103
104.IF "$(SYSTEM_LIBXML)" == "YES"
105SCPDEFS+=-DSYSTEM_LIBXML
106.ENDIF
107
108.IF "$(SYSTEM_LIBWPD)" == "YES"
109SCPDEFS+=-DSYSTEM_LIBWPD
110.ENDIF
111
112.IF "$(SYSTEM_LIBXSLT)" == "YES"
113SCPDEFS+=-DSYSTEM_LIBXSLT
114.ELSE
115.INCLUDE :  libxsltversion.mk
116SCPDEFS+=-DLIBXSLT_MAJOR=$(LIBXSLT_MAJOR)
117.ENDIF
118
119.IF "$(USE_SYSTEM_STL)" == "YES" || "$(STLPORT4)" != "NO_STLPORT4"
120SCPDEFS+=-DUSE_SYSTEM_STL
121.ENDIF
122
123#.IF "$(WITH_MOZILLA)" == "NO"
124#SCPDEFS+=-DWITHOUT_MOZILLA
125#.ENDIF
126
127.IF "$(WITH_MYSPELL_DICTS)" == "NO"
128SCPDEFS+=-DWITHOUT_MYSPELL_DICTS
129.ENDIF
130
131#.IF "$(SYSTEM_MOZILLA)" == "YES"
132#SCPDEFS+=-DSYSTEM_MOZILLA
133#.ENDIF
134
135.IF "$(WITH_LDAP)" == "YES"
136SCPDEFS+=-DWITH_LDAP
137.ENDIF
138
139.IF "$(SYSTEM_CURL)" == "YES"
140SCPDEFS+=-DSYSTEM_CURL
141.ENDIF
142
143.IF "$(SYSTEM_STDLIBS)" == "YES"
144SCPDEFS+=-DSYSTEM_STDLIBS
145.ENDIF
146
147.IF "$(SYSTEM_SNDFILE)" == "YES"
148SCPDEFS+=-DSYSTEM_SNDFILE
149.ENDIF
150
151.IF "$(SYSTEM_PORTAUDIO)" == "YES"
152SCPDEFS+=-DSYSTEM_PORTAUDIO
153.ENDIF
154
155.IF "$(SYSTEM_HUNSPELL)" == "YES"
156SCPDEFS+=-DSYSTEM_HUNSPELL
157.ENDIF
158
159.IF "$(SYSTEM_REDLAND)" == "YES"
160SCPDEFS+=-DSYSTEM_REDLAND
161.ELSE
162.INCLUDE :  redlandversion.mk
163SCPDEFS+=\
164    -DRAPTOR_MAJOR=$(RAPTOR_MAJOR) \
165    -DRASQAL_MAJOR=$(RASQAL_MAJOR) \
166    -DREDLAND_MAJOR=$(REDLAND_MAJOR)
167.ENDIF
168
169.IF "$(SYSTEM_BSH)" == "YES"
170SCPDEFS+=-DSYSTEM_BSH -DBSH_JAR=\""file://$(BSH_JAR)"\"
171.ENDIF
172
173.IF "$(ENABLE_BEANSHELL)" == "YES"
174SCPDEFS+=-DENABLE_BEANSHELL
175.ENDIF
176
177.IF "$(ENABLE_JAVASCRIPT)" == "YES"
178SCPDEFS+=-DENABLE_JAVASCRIPT
179.ENDIF
180
181.IF "$(SYSTEM_HSQLDB)" == "YES"
182SCPDEFS+=-DSYSTEM_HSQLDB -DHSQLDB_JAR=\""file://$(HSQLDB_JAR)"\"
183.ENDIF
184
185.IF "$(SYSTEM_SAXON)" == "YES"
186SCPDEFS+=-DSYSTEM_SAXON -DSAXON_JAR=\""file://$(SAXON_JAR)"\"
187.ENDIF
188
189.IF "$(DISABLE_SAXON)" == "YES"
190SCPDEFS+=-DDISABLE_SAXON
191.ENDIF
192
193.IF "$(DISABLE_LIBWPD)" == "TRUE"
194SCPDEFS+=-DDISABLE_LIBWPD
195.ENDIF
196
197.IF "$(ENABLE_HUNSPELL)" != "YES"
198SCPDEFS+=-DDISABLE_HUNSPELL
199.ENDIF
200
201.IF "$(ENABLE_HYPHEN)" != "YES"
202SCPDEFS+=-DDISABLE_HYPHEN
203.ENDIF
204
205.IF "$(JDK)" == "gcj"
206SCPDEFS+=-DGCJ
207.ENDIF
208
209
210.IF "$(ENABLE_CAIRO)" == "TRUE"
211SCPDEFS+=-DENABLE_CAIRO
212.ENDIF
213
214.IF "$(SYSTEM_LUCENE)" == "YES"
215SCPDEFS+=-DSYSTEM_LUCENE
216.ENDIF
217
218.IF "$(SYSTEM_ICU)" == "YES"
219SCPDEFS+=-DSYSTEM_ICU
220.ELSE
221.INCLUDE :  icuversion.mk
222SCPDEFS+=\
223    -DICU_MAJOR=$(ICU_MAJOR) \
224    -DICU_MINOR=$(ICU_MINOR) \
225    -DICU_MICRO=$(ICU_MICRO)
226.ENDIF
227
228SCPDEFS+=-DISOLANG_MAJOR=$(ISOLANG_MAJOR)
229
230.IF "$(SYSTEM_NEON)" == "YES"
231SCPDEFS+=-DSYSTEM_NEON
232.ENDIF
233
234# if yes or unset (neon not used) -> do not install openssl library!
235.IF $(SYSTEM_OPENSSL) != "YES"
236SCPDEFS+=-DOPENSSL
237.ENDIF
238
239.IF "$(DISABLE_ATL)"!=""
240SCPDEFS+=-DDISABLE_ATL
241.ENDIF
242
243# Detect version numbers for apr, apr-util, serf.
244.IF "$(SYSTEM_APR)"!="YES"
245.INCLUDE : apr_version.mk
246SCPDEFS+=\
247    -DAPR_MAJOR=$(APR_MAJOR)		\
248    -DAPR_MINOR=$(APR_MINOR)		\
249    -DAPR_MICRO=$(APR_MICRO)
250.ENDIF
251.IF "$(SYSTEM_APR_UTIL)"!="YES"
252.INCLUDE : aprutil_version.mk
253SCPDEFS+=\
254    -DAPR_UTIL_MAJOR=$(APR_UTIL_MAJOR)	\
255    -DAPR_UTIL_MINOR=$(APR_UTIL_MINOR)	\
256    -DAPR_UTIL_MICRO=$(APR_UTIL_MICRO)
257.ENDIF
258.IF "$(SYSTEM_SERF)"!="YES"
259.INCLUDE : serf_version.mk
260SCPDEFS+=\
261    -DSERF_MAJOR=$(SERF_MAJOR)		\
262    -DSERF_MINOR=$(SERF_MINOR)		\
263    -DSERF_MICRO=$(SERF_MICRO)
264.ENDIF
265
266.IF "$(SYSTEM_PYTHON)" == "YES"
267SCPDEFS+=-DSYSTEM_PYTHON
268.ENDIF
269
270.IF "$(SYSTEM_LIBTEXTCAT)" == "YES"
271SCPDEFS+=-DSYSTEM_LIBTEXTCAT
272.ENDIF
273
274.IF "$(SYSTEM_LIBTEXTCAT_DATA)" != ""
275SCPDEFS+=-DSYSTEM_LIBTEXTCAT_DATA
276.ENDIF
277
278.IF "$(ENABLE_SVCTAGS)" == "YES"
279SCPDEFS+=-DENABLE_SVCTAGS
280.ENDIF
281
282.IF "$(WITH_VC_REDIST)" == "YES"
283SCPDEFS+=-DWITH_VC_REDIST
284.ENDIF
285
286.IF "$(MINGW_GCCDLL)"!=""
287SCPDEFS+=-DMINGW_GCCDLL=\""$(MINGW_GCCDLL)"\"
288.ENDIF
289
290.IF "$(MINGW_GXXDLL)"!=""
291SCPDEFS+=-DMINGW_GXXDLL=\""$(MINGW_GXXDLL)"\"
292.ENDIF
293
294.IF "$(SYSTEM_GDKPIXBUF)" == "YES"
295SCPDEFS+=-DSYSTEM_GDKPIXBUF
296.ENDIF
297
298.IF "$(SYSTEM_GETTEXT)" == "YES"
299SCPDEFS+=-DSYSTEM_GETTEXT
300.ENDIF
301
302.IF "$(SYSTEM_GLIB)" == "YES"
303SCPDEFS+=-DSYSTEM_GLIB
304.ENDIF
305
306.IF "$(SYSTEM_LIBJPEG)" == "YES"
307SCPDEFS+=-DSYSTEM_LIBJPEG
308.ENDIF
309
310.IF "$(SYSTEM_PANGO)" == "YES"
311SCPDEFS+=-DSYSTEM_PANGO
312.ENDIF
313
314
315# The variables ENABLE_ONLINE_UPDATE, WITHOUT_MATHMLDTD, WITH_CATA_FONTS, WITH_CATB_FONTS,
316# and WITHOUT_PPDS are added (or not) in configure to SCPDEFS.
317
318SCP_PRODUCT_TYPE=osl
319
320ICUVERSION_DEPENDENT_FILES= \
321		$(PAR)$/$(SCP_PRODUCT_TYPE)$/file_library_ooo.par \
322		$(PAR)$/$(SCP_PRODUCT_TYPE)$/shortcut_ooo.par
323
324ISOLANGVERSION_DEPENDENT_FILES= \
325		$(PAR)$/$(SCP_PRODUCT_TYPE)$/file_library_ooo.par
326
327PARFILES=                          \
328        installation_ooo.par       \
329        scpaction_ooo.par          \
330        directory_ooo.par          \
331        directory_ooo_macosx.par   \
332        datacarrier_ooo.par        \
333        file_ooo.par               \
334        file_extra_ooo.par         \
335        file_font_ooo.par          \
336        file_library_ooo.par       \
337        file_resource_ooo.par      \
338        file_improvement.par       \
339        shortcut_ooo.par           \
340        module_ooo.par             \
341        module_hidden_ooo.par      \
342        module_langpack.par        \
343        module_lang_template.par   \
344        module_java.par            \
345        module_systemint.par       \
346        module_improvement.par     \
347        profile_ooo.par            \
348        profileitem_ooo.par        \
349        ure.par                    \
350        ure_into_ooo.par           \
351        ure_standalone.par	   \
352        common_brand.par           \
353        common_brand_readme.par    \
354	ooo_brand.par
355
356
357.IF "$(GUI)"=="WNT"
358PARFILES +=                        \
359        file_jre_ooo.par           \
360        folder_ooo.par             \
361        folderitem_ooo.par         \
362        registryitem_ooo.par       \
363        vc_redist.par              \
364        windowscustomaction_ooo.par
365.ENDIF
366
367ULFFILES=                          \
368        directory_ooo.ulf          \
369        folderitem_ooo.ulf         \
370        module_ooo.ulf             \
371        module_langpack.ulf        \
372        module_java.ulf            \
373        registryitem_ooo.ulf       \
374        module_systemint.ulf
375
376# --- File ---------------------------------------------------------
377.INCLUDE :  target.mk
378
379.IF "$(SYSTEM_ICU)" != "YES"
380$(ICUVERSION_DEPENDENT_FILES) : $(SOLARINCDIR)$/icuversion.mk
381.ENDIF
382
383$(ISOLANGVERSION_DEPENDENT_FILES) : $(SOLARINCDIR)$/i18npool/version.mk
384
385