xref: /aoo41x/main/solenv/inc/wntmsci10.mk (revision 528d5388)
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
28# mk file for $(OS)$(COM)$(CPU)$(COMEX) == WNTMSCI10
29
30SOLAR_JAVA*=TRUE
31FULL_DESK=TRUE
32JAVAFLAGSDEBUG=-g
33
34# SOLAR JAva Unterstuetzung nur fuer wntmsci
35
36ASM=ml
37AFLAGS=/c /Cp /coff /safeseh
38
39# architecture dependent flags for the C and C++ compiler that can be changed by
40# exporting the variable ARCH_FLAGS="..." in the shell, which is used to start build
41ARCH_FLAGS*=
42
43CC*:=cl
44.IF "$(bndchk)" != ""
45CXX*=nmcl
46.ELSE
47.IF "$(truetime)" != ""
48CXX*=nmcl /NMttOn
49.ELSE
50CXX*:=cl
51.ENDIF
52.ENDIF # "$(bndchk)" != ""
53
54.IF "$(stoponerror)" != ""
55CXX+= /NMstoponerror
56.ENDIF
57
58.IF "$(nmpass)" != ""
59CXX+= /NMpass
60.ENDIF
61
62.IF "$(ttinlines)" != ""
63CXX+= /NMttInlines
64.ENDIF
65
66.IF "$(ttnolines)" != ""
67CXX+= /NMttNoLines
68.ENDIF
69
70# Flags for COMEX == 10
71
72CFLAGS+=-Zm500 -Zc:forScope -GR
73CFLAGS+=-c -nologo -Gs $(NOLOGO)
74
75CDEFS+= -D_X86_=1
76
77.IF "$(product)" != ""
78CFLAGS+= -Gy
79.ENDIF # "$(product)" != ""
80
81.IF "$(bndchk)" == ""
82.IF "$(VC_STANDARD)"==""
83CFLAGS+= -Ob1
84.ENDIF	# "$(VC_STANDARD)"==""
85.ENDIF
86
87# flags to enable build with symbols; required for crashdump feature
88#CFLAGSENABLESYMBOLS=-Zi -Fd$(MISC)/_ooo_st_$(TARGET).PDB
89# full debug for RE builds only due to size concerns
90.IF "$(UPDATER)"!=""
91CFLAGSENABLESYMBOLS=-Z7 -Yd
92.ELSE				# "$(UPDATER)"!=""
93# -Zd got higher priority and overrides debug switches
94.IF "$(debug)"==""
95CFLAGSENABLESYMBOLS=-Zd
96.ENDIF			# "$(debug)"==""
97.ENDIF				# "$(UPDATER)"!=""
98
99.IF "$(bndchk)" != ""
100.IF "$(debug)" == ""
101CFLAGS+= -Z7
102.ENDIF
103.ENDIF
104
105.IF "$(truetime)" != ""
106.IF "$(debug)" == ""
107CFLAGS+= -Z7
108.ENDIF
109.ENDIF
110
111.IF "$(FULL_DESK)"!=""
112CDEFS+=-DFULL_DESK
113RSCDEFS+=-DFULL_DESK
114.ENDIF
115
116CFLAGSEXCEPTIONS=-GX
117CFLAGS_NO_EXCEPTIONS=
118
119CFLAGS_CREATE_PCH=-I$(INCPCH) -Fo$(SLO)/pchname.obj -Ycprecompiled_$(PRJNAME).hxx -DPRECOMPILED_HEADERS
120CFLAGS_USE_PCH=-I$(INCPCH) -Yuprecompiled_$(PRJNAME).hxx -Fp$(SLO)/pch/precompiled_$(PRJNAME).hxx$(PCHPOST) -DPRECOMPILED_HEADERS
121CFLAGS_USE_EXCEPTIONS_PCH=-I$(INCPCH) -Yuprecompiled_$(PRJNAME).hxx -Fp$(SLO)/pch_ex/precompiled_$(PRJNAME).hxx$(PCHPOST) -DPRECOMPILED_HEADERS
122.IF "$(CALL_CDECL)"=="TRUE"
123CFLAGSCALL=-Gd
124.ELSE			# "$(CALL_CDECL)"=="TRUE"
125CFLAGSCALL=-Gz
126.ENDIF			# "$(CALL_CDECL)"=="TRUE"
127
128CFLAGSCC=$(ARCH_FLAGS)
129.IF "$(DYNAMIC_CRT)"!=""
130CDEFSSLOMT+=-DWIN32 -D_MT -D_DLL
131CDEFSSLOMT+=-DWIN32 -D_MT -D_DLL
132.IF "$(NO_DYNAMIC_OBJ)"==""
133CDEFSOBJMT+=-DWIN32 -D_MT -D_DLL
134CDEFSOBJMT+=-DWIN32 -D_MT -D_DLL
135.ELSE
136CDEFSOBJMT+=-DWIN32 -D_MT
137CDEFSOBJMT+=-DWIN32 -D_MT
138.ENDIF
139.ELSE
140CDEFSSLOMT+=-DWIN32 -D_MT
141CDEFSSLOMT+=-DWIN32 -D_MT
142CDEFSOBJMT+=-DWIN32 -D_MT
143CDEFSOBJMT+=-DWIN32 -D_MT
144.ENDIF
145CFLAGSPROF=-Gh -Fd$(MISC)/$(@:b).pdb
146CFLAGSDEBUG=-Zi -Fd$(MISC)\_ooo_st_$(TARGET).PDB
147CFLAGSDBGUTIL=
148.IF "$(VC_STANDARD)"==""
149CFLAGSOPT=-Oxs -Oy-
150CFLAGSNOOPT=-Od
151.ELSE			#  "$(VC_STANDARD)"==""
152CFLAGSOPT=
153CFLAGSNOOPT=
154.ENDIF			#  "$(VC_STANDARD)"==""
155CFLAGSOUTOBJ=-Fo
156
157# For C and C++, certain warnings are disabled globally, as they result in
158# spurious warnings and are hard or impossible to workaround:
159# - "warning C4061: enumerate in switch of enum is not explicitly handled by a
160#   case label",
161# - "warning C4063: case 'identifier' is not a valid value for switch of enum
162#   'enumeration'",
163# - "warning C4127: conditional expression is constant",
164# - "warning C4191: unsafe conversion from function type to function type",
165# - "warning C4217: member template functions cannot be used for copy-assignment
166#   or copy-construction",
167# - "warning C4250: 'class1' : inherits 'class2::member' via dominance",
168# - "warning C4292: compiler limit : terminating debug information emission",
169# - "warning C4344: behavior change: use of explicit template arguments results
170#   in call to 'function",
171# - "warning C4347: behavior change: 'overload A' is called instead of
172#   'overload B'",
173# - "warning C4355: 'this' used in base member initializer list",
174# - "warning C4503: 'identifier': decorated name length exceeded, name was
175#   truncated" (http://msdn2.microsoft.com/en-us/library/074af4b6.aspx),
176# - "warning C4511: copy constructor could not be generated",
177# - "warning C4512: assignment operator could not be generated",
178# - "warning C4514: unreferenced inline function has been removed",
179# - "warning C4611: interaction between '_setjmp' and C++ object destruction is
180#   non-portable",
181# - "warning C4619: warning Cnnnn unknown",
182# - "warning C4625: copy constructor could not be generated because a base class
183#   copy constructor is inaccessible",
184# - "warning C4626: assignment operator could not be generated because a base
185#   class assignment operator is inaccessible",
186# - "warning C4675: resolved overload was found by argument-dependent lookup",
187# - "warning C4686: possible change in behavior, change in UDT return calling
188#   convention",
189# - "warning C4710: function not inlined",
190# - "warning C4711: function selected for automatic inline expansion",
191# - "warning C4820: padding added after member".
192# For C, certain warnings from system headers (stdlib.h etc.) have to be
193# disabled globally (for C++, this is not necessary, as the system headers are
194# wrapped by STLport):
195# - "warning C4255: no function prototype given: converting '()' to '(void)'".
196CFLAGSWARNCXX=-Wall -wd4061 -wd4063 -wd4127 -wd4191 -wd4217 -wd4250 -wd4251 \
197    -wd4275 -wd4290 -wd4292 -wd4294 -wd4344 -wd4347 -wd4355 -wd4503 -wd4511 \
198    -wd4512 -wd4514 -wd4611 -wd4619 -wd4625 -wd4626 -wd4640 -wd4675 -wd4686 \
199    -wd4710 -wd4711 -wd4786 -wd4800 -wd4820
200CFLAGSWARNCC=$(CFLAGSWARNCXX) -wd4255
201CFLAGSWALLCC=$(CFLAGSWARNCC)
202CFLAGSWALLCXX=$(CFLAGSWARNCXX)
203CFLAGSWERRCC=-WX
204
205# Once all modules on this platform compile without warnings, set
206# COMPILER_WARN_ERRORS=TRUE here instead of setting MODULES_WITH_WARNINGS (see
207# settings.mk):
208MODULES_WITH_WARNINGS := \
209    lingucomponent \
210    soldep
211
212CDEFS+=-DSTLPORT_VERSION=$(STLPORT_VER) -D_MT -DWINVER=0x0500 -D_WIN32_WINNT=0x0500 -D_WIN32_IE=0x0500
213
214COMMENTFLAG=/COMMENT:"$(PRJNAME)_$(UPD)_$(VCSID)_"
215
216LINK=link $(COMMENTFLAG) $(NOLOGO) /MACHINE:IX86
217LINKOUTPUTFILTER= $(PIPEERROR) $(GREP) -v "LNK4197:"
218.IF "$(PRODUCT)"!="full"
219.ELSE
220LINKFLAGS=/MAP /OPT:NOREF
221.ENDIF
222
223.IF "$(linkinc)" != ""
224LINKFLAGS=-NODEFAULTLIB -DEBUG:full -DEBUGTYPE:cv -INCREMENTAL:YES
225MAPFILE=
226.ELSE # "$(linkinc)" != ""
227.IF "$(PRODUCT)"!="full"
228LINKFLAGS+= -NODEFAULTLIB -DEBUG:full -DEBUGTYPE:cv
229.ELSE # "$(PRODUCT)"!="full"
230LINKFLAGS+= -NODEFAULTLIB -RELEASE -DEBUG:full
231.ENDIF # "$(PRODUCT)"!="full"
232MAPFILE=-out:$$@
233.ENDIF # "$(linkinc)" != ""
234
235.IF "$(bndchk)" != ""
236LINK=nmlink $(COMMENTFLAG) $(NOLOGO) -MACHINE:IX86
237LINKFLAGS=-NODEFAULTLIB -DEBUG:full -DEBUGTYPE:cv
238.ENDIF
239
240.IF "$(truetime)" != ""
241LINK=nmlink /NMttOn $(COMMENTFLAG) $(NOLOGO) /MACHINE:IX86
242LINKFLAGS=/NODEFAULTLIB /DEBUG:full /DEBUGTYPE:cv
243.ENDIF
244
245LINKFLAGSAPPGUI=/SUBSYSTEM:WINDOWS,4.0
246LINKFLAGSSHLGUI=/SUBSYSTEM:WINDOWS,4.0 /DLL
247LINKFLAGSAPPCUI=/SUBSYSTEM:CONSOLE /BASE:0x1b000000
248LINKFLAGSSHLCUI=/SUBSYSTEM:CONSOLE /DLL
249LINKFLAGSTACK=/STACK:
250LINKFLAGSPROF=-DEBUG:mapped,partial -DEBUGTYPE:coff cap.lib
251LINKFLAGSWST=-DEBUG:mapped,partial -DEBUGTYPE:coff wst.lib -NODEFAULTLIB
252LINKFLAGSDEBUG=-DEBUG:full -DEBUGTYPE:cv
253LINKFLAGSOPT=
254
255UWINAPILIB*=uwinapi.lib
256.IF "$(DYNAMIC_CRT)"!=""
257.IF "$(USE_STLP_DEBUG)" != ""
258LIBCMT=msvcrtd.lib
259.ELSE  # "$(USE_STLP_DEBUG)" != ""
260LIBCMT=msvcrt.lib
261.ENDIF # "$(USE_STLP_DEBUG)" != ""
262.ELSE			# "$(DYNAMIC_CRT)"!=""
263.IF "$(USE_STLP_DEBUG)" != ""
264LIBCMT=libcmtd.lib
265.ELSE  # "$(USE_STLP_DEBUG)" != ""
266LIBCMT=libcmt.lib
267.ENDIF # "$(USE_STLP_DEBUG)" != ""
268.ENDIF			# "$(DYNAMIC_CRT)"!=""
269
270STDOBJVCL=$(L)/salmain.obj
271STDOBJGUI=
272STDSLOGUI=
273STDOBJCUI=
274STDSLOCUI=
275
276STDLIBGUIMT=$(LIBCMT) $(UWINAPILIB) kernel32.lib user32.lib oldnames.lib psapi.lib
277STDLIBCUIMT=$(LIBCMT) $(UWINAPILIB) kernel32.lib user32.lib oldnames.lib psapi.lib
278STDSHLGUIMT=$(LIBCMT) $(UWINAPILIB) kernel32.lib user32.lib oldnames.lib psapi.lib
279STDSHLCUIMT=$(LIBCMT) $(UWINAPILIB) kernel32.lib user32.lib oldnames.lib psapi.lib
280
281.IF "$(USE_STLP_DEBUG)" != ""
282CFLAGS+=-MTd
283LIBSTLPORT=stlport_vc71_stldebug.lib
284LIBSTLPORTST=stlport_vc71_stldebug_static.lib
285.ELSE
286LIBSTLPORT=stlport_vc71.lib
287LIBSTLPORTST=stlport_vc71_static.lib
288.ENDIF
289
290ATL_INCLUDE*=$(COMPATH)/atlmfc/include
291ATL_LIB*=$(COMPATH)/atlmfc/lib
292
293LIBMGR=lib $(NOLOGO)
294IMPLIB=lib
295LIBFLAGS=
296
297IMPLIBFLAGS=-machine:IX86
298
299MAPSYM=
300MAPSYMFLAGS=
301
302RC=rc
303RCFLAGS=-r -DWIN32 -fo$@ $(RCFILES)
304RCLINK=rc
305RCLINKFLAGS=
306RCSETVERSION=
307
308
309DLLPOSTFIX=
310PCHPOST=.pch
311
312CSC*=$(FLIPCMD) csc
313VBC*=vbc
314
315ADVAPI32LIB=advapi32.lib
316SHELL32LIB=shell32.lib
317GDI32LIB=gdi32.lib
318OLE32LIB=ole32.lib
319OLEAUT32LIB=oleaut32.lib
320UUIDLIB=uuid.lib
321WINSPOOLLIB=winspool.lib
322IMM32LIB=imm32.lib
323VERSIONLIB=version.lib
324WINMMLIB=winmm.lib
325WSOCK32LIB=wsock32.lib
326MPRLIB=mpr.lib
327WS2_32LIB=ws2_32.lib
328KERNEL32LIB=kernel32.lib
329USER32LIB=user32.lib
330COMDLG32LIB=comdlg32.lib
331COMCTL32LIB=comctl32.lib
332CRYPT32LIB=crypt32.lib
333GDIPLUSLIB=gdiplus.lib
334DBGHELPLIB=dbghelp.lib
335MSILIB=msi.lib
336DDRAWLIB=ddraw.lib
337SHLWAPILIB=shlwapi.lib
338URLMONLIB=urlmon.lib
339WININETLIB=wininet.lib
340OLDNAMESLIB=oldnames.lib
341MSIMG32LIB=msimg32.lib
342
343