merge the formfield patch from ooo-build
[ooovba.git] / solenv / inc / os2.mk
blob03ad2f7a35da465d9e2d65ef59b089e9282c70e8
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: os2.mk,v $
11 # $Revision: 1.6 $
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 # --- OS2-Environment ----------------------------------------------
34 .IF "$(GUI)" == "OS2"
36 # YD defined in os2env.cmd
37 #.IF "$(NOSOLAR_JAVA)"==""
38 #SOLAR_JAVA=TRUE
39 #.ENDIF
41 .IF "$(SOLAR_JAVA)"!=""
42 JAVADEF=-DSOLAR_JAVA
43 .ENDIF
44 JAVAFLAGSDEBUG=-g
46 # --- Borland ---
47 .IF "$(COM)" == "BLC"
49 JAVADEF=-DSOLAR_JAVA
51 ASM=tasm
52 AFLAGS=
54 CXX=bcc
55 CC=bcc
56 CFLAGS=-c -3 -a1 -X -d -wbbf -weas -wucp -w-hid -w-par -I. $(MINUS_I)$(INCLUDE)
57 CFLAGSCXX=-Pcxx -RT- -x- -V
58 CFLAGSOBJGUIST=
59 CFLAGSOBJCUIST=
60 CFLAGSOBJGUIMT=-sm
61 CFLAGSOBJCUIMT=-sm
62 CFLAGSSLOGUIMT=-sm -sd
63 CFLAGSSLOCUIMT=-sm -sd
64 CFLAGSPROF=
65 CFLAGSDEBUG=-v
66 CFLAGSDBGUTIL=
67 CFLAGSOPT=-Os -Ob -k-
68 CFLAGSNOOPT=-Od
69 CFLAGSOUTOBJ=-o
71 LINK=tlink
72 LINKFLAGS=/m /L$(LIB)
73 #LINKFLAGSAPPGUI=/Toe /B:0x10000 /aa
74 #Base wg. lxopt raus
75 LINKFLAGSAPPGUI=/Toe /aa
76 LINKFLAGSSHLGUI=/Tod
77 LINKFLAGSAPPCUI=/Toe /B:0x10000 /ap
78 LINKFLAGSSHLCUI=/Tod
79 LINKFLAGSTACK=/S:
80 LINKFLAGSPROF=
81 LINKFLAGSDEBUG=/v
82 .IF "$(SOLAR_JAVA)"==""
83 LINKFLAGSOPT=/Oc
84 .ENDIF
86 STDOBJVCL=$(L)/salmain.obj
87 STDOBJGUI=c02.obj
88 STDSLOGUI=c02d.obj
89 STDOBJCUI=c02.obj
90 STDSLOCUI=c02d.obj
91 STDLIBGUIST=c2.lib os2.lib
92 STDLIBCUIST=c2.lib os2.lib
93 STDLIBGUIMT=c2mt.lib os2.lib
94 STDLIBCUIMT=c2mt.lib os2.lib
95 STDSHLGUIMT=c2mt.lib os2.lib
96 STDSHLCUIMT=c2mt.lib os2.lib
98 LIBMGR=tlib
99 LIBFLAGS=/C /P128
101 IMPLIB=implib
102 IMPLIBFLAGS=/c
104 MAPSYM=
105 MAPSYMFLAGS=
107 RC=rc
108 RCFLAGS=-r $(RCFILES) $@
109 RCLINK=rc
110 RCLINKFLAGS=
111 RCSETVERSION=
113 DLLPOSTFIX=bo
115 .ENDIF
117 # --- IBM ---
118 .IF "$(COM)" == "ICC"
120 ASM=tasm
121 AFLAGS=/ml /oi
123 CXX=icc
124 CC=icc
125 .IF "$(COMEX)"=="3"
126 CFLAGS=/C+ /Q+ /Gf+ /Sp1 /G4 /Se /Gs+ /Gt+ /Gd+ /J- /W2 /D__EXTENDED__ /Si+ /Xi+ $(MINUS_I)$(INCLUDE) /Wvft-
127 .ELSE
128 .IF "$(COMEX)"=="I"
129 CFLAGS=/C+ /Tl10 /Q+ /Gf+ /Sp4 /G4 /Sc /Gs- /D__EXTENDED__ /Si+ /Su4
130 .ELSE
131 CFLAGS=/C+ /Tl10 /Q+ /Gf+ /Sp1 /G4 /Sc /Gs+ /D__EXTENDED__ /Si+
132 .ENDIF
133 .ENDIF
135 CFLAGSCXX=/Tdp
137 CFLAGSEXCEPTIONS=-Gx-
138 CFLAGS_NO_EXCEPTIONS=-Gx+
140 CFLAGSOBJGUIST=/Ge+
141 CFLAGSOBJCUIST=/Ge+
142 .IF "$(COMEX)"=="I"
143 CFLAGSOBJGUIMT=/Ge+ /Gm+
144 CFLAGSOBJCUIMT=/Ge+ /Gm+
145 CFLAGSSLOGUIMT=/Ge- /Gm+
146 CFLAGSSLOCUIMT=/Ge- /Gm+
147 .ELSE
148 CFLAGSOBJGUIMT=/Ge+ /Gm+
149 CFLAGSOBJCUIMT=/Ge+ /Gm+
150 CFLAGSSLOGUIMT=/Ge- /Gm+
151 CFLAGSSLOCUIMT=/Ge- /Gm+
152 .ENDIF
153 CFLAGSPROF=/Gh+
154 CFLAGSDEBUG=/Ti+
155 CFLAGSDBGUTIL=
156 CFLAGSOPT=/O+ /Oi+ /Oc+
157 CFLAGSNOOPT=/O-
158 CFLAGSOUTOBJ=/Fo
160 CDEFS+=-D_STD_NO_NAMESPACE -D_VOS_NO_NAMESPACE -D_UNO_NO_NAMESPACE
162 LINK=ilink
163 #LINKFLAGS=/PACKCODE:8192 /ALIGN:16 /NOD /NOE /NOI /MAP /NOFREE
165 #bei too many segments ist /SEGMENTS:nnnn hilfreich. 3072 ist max!
166 .IF "$(CPPRTST)"!=""
167 LINKFLAGS=/NOFREE /NOD /NOE /NOI /MAP /OPTFUNC /PACKD:65536 /EXEPACK:2
168 .ELSE
169 LINKFLAGS=/NOFREE /NOD /NOE /NOI /MAP /OPTFUNC /PACKD:65536
170 .ENDIF
171 LINKFLAGSAPPGUI=/PM:PM /NOBASE
172 LINKFLAGSSHLGUI=
173 LINKFLAGSAPPCUI=/PM:VIO /NOBASE
174 LINKFLAGSSHLCUI=
175 LINKFLAGSTACK=/STACK:
176 LINKFLAGSPROF=
177 LINKFLAGSDEBUG=/COD
178 #LINKFLAGSOPT=/EXEPACK:2 /OPTFUNC
179 LINKFLAGSOPT=
180 #.IF "$(product)"!="full" && "$(product)"!="demo" && "$(product)"!="compact"
181 #LINKFLAGS=$(LINKFLAGS) /COD
182 #.ELSE
183 #LINKFLAGS=$(LINKFLAGS)
184 #.ENDIF
186 .IF "$(product)"=="full" || "$(product)"=="demo" || "$(product)"=="compact"
187 # LINKFLAGS=$(LINKFLAGS)
188 .ELSE
189 LINKFLAGS+=/COD
190 .ENDIF
192 STDOBJVCL=$(L)/salmain.obj
193 STDOBJGUI=
194 STDSLOGUI=
195 STDOBJCUI=
196 STDSLOCUI=
197 .IF "$(COMEX)"=="3"
198 .IF "$(CPPRTST)"!=""
199 STDLIBGUIST=cppom30o.lib cpprtst.lib os2386.lib
200 STDLIBCUIST=cppom30o.lib cpprtst.lib os2386.lib
201 STDLIBGUIMT=cppom30o.lib cpprtst.lib os2386.lib
202 STDLIBCUIMT=cppom30o.lib cpprtst.lib os2386.lib
203 STDSHLGUIMT=cppom30o.lib cpprtst.lib os2386.lib
204 STDSHLCUIMT=cppom30o.lib cpprtst.lib os2386.lib
205 .ELSE
206 STDLIBGUIST=cppom30o.lib cppom30i.lib os2386.lib
207 STDLIBCUIST=cppom30o.lib cppom30i.lib os2386.lib
208 STDLIBGUIMT=cppom30o.lib cppom30i.lib os2386.lib
209 STDLIBCUIMT=cppom30o.lib cppom30i.lib os2386.lib
210 STDSHLGUIMT=cppom30o.lib cppom30i.lib os2386.lib
211 STDSHLCUIMT=cppom30o.lib cppom30i.lib os2386.lib
212 .ENDIF
213 .ELSE
214 STDLIBGUIST=dde4sbs.lib os2386.lib
215 STDLIBCUIST=dde4sbs.lib os2386.lib
216 STDLIBGUIMT=dde4mbs.lib os2386.lib
217 STDLIBCUIMT=dde4mbs.lib os2386.lib
218 STDSHLGUIMT=dde4mbs.lib os2386.lib
219 STDSHLCUIMT=dde4mbs.lib os2386.lib
220 .ENDIF
222 .IF "$(COMEX)"=="3"
223 LIBMGR=ilib
224 .ELSE
225 LIBMGR=lib
226 .ENDIF
227 LIBFLAGS=/NOI
229 IMPLIB=implib
230 IMPLIBFLAGS=/noi
232 MAPSYM=
233 MAPSYMFLAGS=
235 RC=rc
236 RCFLAGS=-r $(RCFILES) $@
237 RCLINK=rc
238 RCLINKFLAGS=
239 RCSETVERSION=
241 DLLPOSTFIX=co
243 .ENDIF
245 # --- GNU ---
246 .IF "$(COM)" == "GCC"
248 .INCLUDE : os2gcci.mk
250 .ENDIF
252 # --- Watcom ---
253 .IF "$(COM)" == "WTC"
255 ASM=wasm
256 AFLAGS=/ml /4pr
258 CC=wcl386
259 CXX=wcl386
260 .IF "$(e2p)" != ""
261 CFLAGS=-c -W3 -Zp4 -Zld $(MINUS_I)$(INCLUDE) -bt=os2 -zq -zm -ep -ee
262 .ELSE
263 CFLAGS=-c -Zp4 -W3 -Zl -Zld $(MINUS_I)$(INCLUDE) -bt=os2 -zq -s
264 .ENDIF
265 CFLAGSCXX=-cc++ -xst
266 CFLAGSOBJGUIST= #-Alfd -GA -GEfs
267 CFLAGSOBJCUIST=
268 CFLAGSOBJGUIMT=-bm #-Alfw -GA -GEd
269 CFLAGSOBJCUIMT=-bm
270 CFLAGSSLOGUIMT=-bm -bd #-Alfw -GD -GEfd
271 CFLAGSSLOCUIMT=-bm -bd
272 CFLAGSPROF=
273 CFLAGSDEBUG=/d2
274 CFLAGSDBGUTIL=
275 .IF "$(e2p)" != ""
276 CFLAGSOPT=-otexan -3s
277 CFLAGSNOOPT=-od -3s
278 .ELSE
279 CFLAGSOPT=-otexan -4s
280 CFLAGSNOOPT=-od -4s
281 .ENDIF
282 CFLAGSOUTOBJ=-Fo
284 LINK=wlink
285 LINKFLAGS=op symf op caseexact op statics op MANY
286 LINKFLAGSAPPGUI=sys os2v2 pm
287 LINKFLAGSSHLGUI=sys os2v2 dll INITINSTANCE TERMINSTANCE
288 LINKFLAGSAPPCUI=sys os2v2
289 LINKFLAGSSHLCUI=sys os2v2 dll
290 LINKFLAGSTACK=op stack=
291 LINKFLAGSPROF=
292 LINKFLAGSDEBUG=debug all op undefsok
293 LINKFLAGSOPT=
295 STDOBJVCL=$(L)/salmain.obj
296 STDOBJGUI=libr clib3s.lib libr plib3s.lib libr math387s.lib
297 STDSLOGUI=libr clib3s.lib libr os2386.lib libr plib3s.lib libr math387s.lib
298 STDOBJCUI=libr clib3s.lib libr plib3s.lib libr math387s.lib
299 STDSLOCUI=libr clib3s.lib libr plib3s.lib libr math387s.lib
300 STDLIBGUIST=libr os2386.lib libr clib3s.lib libr plib3s.lib
301 STDLIBCUIST=libr os2386.lib libr clib3s.lib libr plib3s.lib
302 STDLIBGUIMT=libr os2386.lib libr clib3s.lib libr plib3s.lib
303 STDLIBCUIMT=libr os2386.lib libr clib3s.lib libr plib3s.lib
304 STDSHLGUIMT=libr os2386.lib libr clib3s.lib libr plibmt3s.lib libr math387s.lib libr plib3s.lib libr noemu387.lib
305 STDSHLCUIMT=libr os2386.lib libr clib3s.lib libr plibmt3s.lib libr matg387s.lib libr plib3s.lib
307 LIBMGR=wlib
308 LIBFLAGS=/p=128 /c /m
310 IMPLIB=echo
311 IMPLIBFLAGS=
313 MAPSYM=mapsym
314 MAPSYMFLAGS=
316 RC=rc
317 RCFLAGS=-r $(RCFILES) $@
318 RCLINK=rc
319 RCLINKFLAGS=
320 RCSETVERSION=
322 DLLPOSTFIX=wo
324 .ENDIF
326 # --- OS2 Allgemein ---
327 HC=toipf
328 HCFLAGS=
329 PATH_SEPERATOR*=;
330 DLLPRE=
331 DLLPOST=.dll
332 EXECPOST=.exe
333 SCPPOST=.ins
334 DLLDEST=$(BIN)
335 SOLARSHAREDBIN=$(SOLARBINDIR)
337 .ENDIF