Update ooo320-m1
[ooovba.git] / desktop / util / makefile.mk
blob05f129b3c5fc7f2efd58d37cfa997f3ba4a89fca
1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 #
5 # Copyright 2008 by Sun Microsystems, Inc.
7 # OpenOffice.org - a multi-platform office productivity suite
9 # $RCSfile: makefile.mk,v $
11 # $Revision: 1.83 $
13 # This file is part of OpenOffice.org.
15 # OpenOffice.org is free software: you can redistribute it and/or modify
16 # it under the terms of the GNU Lesser General Public License version 3
17 # only, as published by the Free Software Foundation.
19 # OpenOffice.org is distributed in the hope that it will be useful,
20 # but WITHOUT ANY WARRANTY; without even the implied warranty of
21 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 # GNU Lesser General Public License version 3 for more details
23 # (a copy is included in the LICENSE file that accompanied this code).
25 # You should have received a copy of the GNU Lesser General Public License
26 # version 3 along with OpenOffice.org. If not, see
27 # <http://www.openoffice.org/license.html>
28 # for a copy of the LGPLv3 License.
30 #*************************************************************************
32 PRJ=..
34 PRJNAME=desktop
35 TARGET=soffice
36 TARGETTYPE=GUI
37 LIBTARGET=NO
38 GEN_HID=TRUE
39 GEN_HID_OTHER=TRUE
41 # --- Settings -----------------------------------------------------------
43 .INCLUDE : settings.mk
45 UWINAPILIB =
47 VERINFONAME=verinfo
49 # --- Resourcen ----------------------------------------------------
51 .IF "$(GUI)" == "WNT"
52 RCFILES=verinfo.rc
53 .ENDIF
54 .IF "$(GUI)" == "OS2"
55 RCFILES=ooverinfo2.rc
56 .ENDIF
58 # --- Linken der Applikation ---------------------------------------
60 .IF "$(OS)" == "MACOSX"
61 LINKFLAGSAPPGUI!:= $(LINKFLAGSAPPGUI:s/-bind_at_load//)
62 .ENDIF # MACOSX
64 #.IF "$(OS)" == "LINUX" || "$(OS)" == "FREEBSD" || "$(OS)" == "NETBSD"
65 ## #74158# linux needs sal/vos/tools at end of link list, solaris needs it first,
66 ## winXX is handled like solaris for now
67 #APP1_STDPRE=
68 #APP1_STDPOST=$(CPPULIB) $(CPPUHELPERLIB) $(UNOLIB) $(TOOLSLIB) \
69 # $(VOSLIB) $(SALLIB)
70 #.ELSE
71 #APP1_STDPRE=$(SALLIB) $(VOSLIB) $(TOOLSLIB) $(UNOLIB) $(CPPULIB) \
72 # $(CPPUHELPERLIB)
73 #APP1_STDPOST=
74 #.ENDIF
76 RESLIB1NAME= dkt
77 RESLIB1IMAGES= $(PRJ)$/res
78 RESLIB1SRSFILES= $(SRS)$/desktop.srs \
79 $(SRS)$/wizard.srs
81 .IF "$(L10N_framework)"==""
82 .IF "$(GUI)" != "OS2"
83 APP1TARGET=so$/$(TARGET)
84 APP1NOSAL=TRUE
85 APP1RPATH=BRAND
86 APP1OBJS=$(OBJ)$/copyright_ascii_sun.obj $(OBJ)$/main.obj
87 APP1STDLIBS = \
88 $(SALLIB) \
89 $(SOFFICELIB) \
90 $(COMPHELPERLIB) \
91 $(CPPUHELPERLIB) \
92 $(CPPULIB) \
93 $(I18NISOLANGLIB) \
94 $(SALLIB) \
95 $(SFXLIB) \
96 $(SVLLIB) \
97 $(SVTOOLLIB) \
98 $(TKLIB) \
99 $(TOOLSLIB) \
100 $(UCBHELPERLIB) \
101 $(UNOTOOLSLIB) \
102 $(VCLLIB) \
103 $(FWELIB) \
104 $(BASICLIB) \
105 $(XMLSCRIPTLIB) \
106 $(SALHELPERLIB) \
107 $(SOTLIB) \
108 $(SAXLIB) \
109 $(FWILIB) \
110 $(ICUUCLIB) \
111 $(I18NUTILLIB) \
112 $(ICULIB) \
113 $(JVMFWKLIB) \
114 $(BASEGFXLIB) \
115 $(ICUDATALIB) \
116 $(ICULELIB) \
117 $(JVMACCESSLIB) \
118 $(SALHELPERLIB) \
119 $(VOSLIB)
122 .IF "$(GUI)" == "UNX"
123 .IF "$(OS)" == "LINUX" || "$(OS)" == "FREEBSD"
124 APP1STDLIBS+= -lXext
125 .ENDIF
126 .ENDIF
128 APP1DEPN= $(APP1RES) verinfo.rc
130 .IF "$(GUI)" == "WNT"
131 APP1RES= $(RES)$/desktop.res
132 APP1ICON=$(SOLARRESDIR)$/icons/so9_main_app.ico
133 APP1VERINFO=verinfo.rc
134 APP1LINKRES=$(MISC)$/$(TARGET)1.res
135 APP1STACK=10000000
137 # create a manifest file with the same name as the
138 #office executable file soffice.exe.manifest
139 #$(BIN)$/$(TARGET).exe.manifest: template.manifest
140 #$(COPY) $< $@
142 .ENDIF # WNT
144 .ENDIF # "$(GUI)" != "OS2"
146 APP5TARGET=soffice
147 APP5NOSAL=TRUE
148 APP5RPATH=BRAND
149 APP5OBJS=$(OBJ)$/copyright_ascii_ooo.obj $(OBJ)$/main.obj
150 APP5STDLIBS = \
151 $(SALLIB) \
152 $(SOFFICELIB) \
153 $(COMPHELPERLIB) \
154 $(CPPUHELPERLIB) \
155 $(CPPULIB) \
156 $(I18NISOLANGLIB) \
157 $(SALLIB) \
158 $(SFXLIB) \
159 $(SVLLIB) \
160 $(SVTOOLLIB) \
161 $(TKLIB) \
162 $(TOOLSLIB) \
163 $(UCBHELPERLIB) \
164 $(UNOTOOLSLIB) \
165 $(VCLLIB) \
166 $(FWELIB) \
167 $(BASICLIB) \
168 $(XMLSCRIPTLIB) \
169 $(SALHELPERLIB) \
170 $(SOTLIB) \
171 $(SAXLIB) \
172 $(FWILIB) \
173 $(ICUUCLIB) \
174 $(I18NUTILLIB) \
175 $(ICULIB) \
176 $(JVMFWKLIB) \
177 $(BASEGFXLIB) \
178 $(ICUDATALIB) \
179 $(ICULELIB) \
180 $(JVMACCESSLIB) \
181 $(SALHELPERLIB) \
182 $(VOSLIB)
184 .IF "$(OS)" == "LINUX"
185 APP5STDLIBS+= -lXext
186 #APP5STDLIBS+= -lXext -lSM -lICE
187 .ENDIF # LINUX
189 APP5DEPN= $(APP1TARGETN) $(APP5RES) ooverinfo.rc
190 APP5DEF= $(MISCX)$/$(TARGET).def
192 .IF "$(GUI)" == "WNT"
193 APP5RES= $(RES)$/oodesktop.res
194 APP5ICON=$(SOLARRESDIR)$/icons/ooo3_main_app.ico
195 APP5VERINFO=ooverinfo.rc
196 APP5LINKRES=$(MISC)$/ooffice5.res
197 APP5STACK=10000000
198 .ENDIF # WNT
200 .IF "$(GUI)" == "OS2"
201 APP5DEF= # automatic
202 APP5RES= $(RES)$/oodesktop.res
203 APP5ICON=$(SOLARRESDIR)$/icons/ooo-main-app.ico
204 APP5VERINFO=ooverinfo2.rc
205 APP5LINKRES=$(MISC)$/ooffice.res
206 .ENDIF # OS2
208 .IF "$(GUI)" == "WNT"
209 APP6TARGET=so$/officeloader
210 APP6RES=$(RES)$/soloader.res
211 APP6NOSAL=TRUE
212 APP6DEPN= $(APP1TARGETN) $(APP6RES) verinfo.rc
213 APP6VERINFO=verinfo.rc
214 APP6LINKRES=$(MISC)$/soffice6.res
215 APP6ICON=$(SOLARRESDIR)$/icons/so9_main_app.ico
216 APP6OBJS = \
217 $(OBJ)$/extendloaderenvironment.obj \
218 $(OBJ)$/officeloader.obj \
219 $(SOLARLIBDIR)$/pathutils-obj.obj
220 STDLIB6=$(ADVAPI32LIB) $(SHELL32LIB) $(SHLWAPILIB)
222 APP7TARGET=officeloader
223 APP7RES=$(RES)$/ooloader.res
224 APP7NOSAL=TRUE
225 APP7DEPN= $(APP1TARGETN) $(APP7RES) ooverinfo.rc
226 APP7VERINFO=ooverinfo.rc
227 APP7LINKRES=$(MISC)$/ooffice7.res
228 APP7ICON=$(SOLARRESDIR)$/icons/ooo3_main_app.ico
229 APP7OBJS = \
230 $(OBJ)$/extendloaderenvironment.obj \
231 $(OBJ)$/officeloader.obj \
232 $(SOLARLIBDIR)$/pathutils-obj.obj
233 STDLIB7=$(ADVAPI32LIB) $(SHELL32LIB) $(SHLWAPILIB)
234 .ELIF "$(OS)" == "MACOSX"
235 APP6TARGET=officeloader
236 APP6NOSAL=TRUE
237 APP6RPATH=BRAND
238 APP6OBJS=$(OBJ)$/copyright_ascii_ooo.obj $(OBJ)$/officeloader.obj
239 APP6STDLIBS = $(SALLIB)
240 APP5DEPN= $(APP1TARGETN) $(APP5RES) ooverinfo.rc
241 APP5DEF= $(MISCX)$/$(TARGET).def
242 .ENDIF # WNT
244 .ENDIF
246 # --- Targets -------------------------------------------------------------
248 .INCLUDE : target.mk
250 .IF "$(L10N_framework)"==""
252 .IF "$(APP1TARGETN)"!=""
253 $(APP1TARGETN) : $(MISC)$/binso_created.flg
254 .ENDIF # "$(APP1TARGETN)"!=""
256 .IF "$(APP5TARGETN)"!=""
257 $(APP5TARGETN) : $(MISC)$/binso_created.flg
258 .ENDIF # "$(APP6TARGETN)"!=""
260 .IF "$(APP6TARGETN)"!=""
261 $(APP6TARGETN) : $(MISC)$/binso_created.flg
262 .ENDIF # "$(APP6TARGETN)"!=""
264 .IF "$(GUI)" == "WNT"
265 ALLTAR: $(MISC)$/$(TARGET).exe.manifest
266 ALLTAR: $(MISC)$/$(TARGET).bin.manifest
267 ALLTAR: $(BIN)$/$(TARGET).bin
268 ALLTAR: $(BIN)$/so$/$(TARGET).bin
269 .ENDIF # WNT
271 .IF "$(GUI)" == "OS2"
272 ALLTAR: $(BIN)$/$(TARGET).bin
273 .ENDIF # OS2
275 $(BIN)$/soffice_oo$(EXECPOST) : $(APP5TARGETN)
276 $(COPY) $< $@
278 .IF "$(GUI)" != "OS2"
279 $(BIN)$/so$/soffice_so$(EXECPOST) : $(APP1TARGETN)
280 $(COPY) $< $@
282 ALLTAR : $(BIN)$/so$/soffice_so$(EXECPOST) $(BIN)$/soffice_oo$(EXECPOST)
284 .ENDIF
286 .IF "$(OS)" == "MACOSX"
287 $(BIN)$/so$/soffice_mac$(EXECPOST) : $(APP1TARGETN)
288 $(COPY) $< $@
290 $(BIN)$/soffice_mac$(EXECPOST) : $(APP5TARGETN)
291 $(COPY) $< $@
293 ALLTAR : $(BIN)$/so$/soffice_mac$(EXECPOST) $(BIN)$/soffice_mac$(EXECPOST)
295 .ENDIF
297 .IF "$(GUI)" == "WNT"
299 # create a manifest file with the same name as the
300 # office executable file soffice.exe.manifest
301 .IF "$(CCNUMVER)" <= "001399999999"
302 $(MISC)$/$(TARGET).exe.manifest: template.manifest
303 $(COPY) $< $@
304 .ELSE
305 $(MISC)$/$(TARGET).exe.template.manifest: template.manifest
306 $(COPY) $< $@
308 $(MISC)$/$(TARGET).exe.linker.manifest: $(BIN)$/$(TARGET)$(EXECPOST)
309 mt.exe -inputresource:$(BIN)$/$(TARGET)$(EXECPOST) -out:$@
311 $(MISC)$/$(TARGET).exe.manifest: $(MISC)$/$(TARGET).exe.template.manifest $(MISC)$/$(TARGET).exe.linker.manifest
312 mt.exe -manifest $(MISC)$/$(TARGET).exe.linker.manifest $(MISC)$/$(TARGET).exe.template.manifest -out:$@
313 .ENDIF
315 # create a manifest file with the same name as the
316 # office executable file soffice.bin.manifest
317 .IF "$(CCNUMVER)" <= "001399999999"
318 $(MISC)$/$(TARGET).bin.manifest: template.manifest
319 $(COPY) $< $@
320 .ELSE
321 $(MISC)$/$(TARGET).bin.manifest: $(MISC)$/$(TARGET).exe.manifest
322 $(COPY) $(MISC)$/$(TARGET).exe.manifest $@
323 .ENDIF
325 $(BIN)$/$(TARGET).bin: $(BIN)$/$(TARGET)$(EXECPOST)
326 $(COPY) $< $@
328 $(BIN)$/so$/$(TARGET).bin: $(BIN)$/so$/$(TARGET)$(EXECPOST)
329 $(COPY) $< $@
331 .ENDIF # WNT
333 .IF "$(GUI)" == "OS2"
334 $(BIN)$/$(TARGET).bin: $(BIN)$/$(TARGET)$(EXECPOST)
335 $(COPY) $< $@
336 .ENDIF # OS2
338 $(MISC)$/binso_created.flg :
339 @@-$(MKDIRHIER) $(BIN)$/so && $(TOUCH) $@
341 .ENDIF