Subversion Repositories planix.SVN

Rev

Rev 2 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
#    Copyright (C) 1997, 2000 Aladdin Enterprises.  All rights reserved.
2
# 
3
# This software is provided AS-IS with no warranty, either express or
4
# implied.
5
# 
6
# This software is distributed under license and may not be copied,
7
# modified or distributed except as expressly authorized under the terms
8
# of the license contained in the file LICENSE in this distribution.
9
# 
10
# For more information about licensing, please refer to
11
# http://www.ghostscript.com/licensing/. For information on
12
# commercial licensing, go to http://www.artifex.com/licensing/ or
13
# contact Artifex Software, Inc., 101 Lucas Valley Road #110,
14
# San Rafael, CA  94903, U.S.A., +1(415)492-9861.
15
 
16
# $Id: msvccmd.mak,v 1.27 2005/07/12 17:54:55 igor Exp $
17
# Command definition section for Microsoft Visual C++ 4.x/5.x,
18
# Windows NT or Windows 95 platform.
19
# Created 1997-05-22 by L. Peter Deutsch from msvc4/5 makefiles.
20
# edited 1997-06-xx by JD to factor out interpreter-specific sections
21
# edited 2000-03-30 by lpd to make /FPi87 conditional on MSVC version
22
# edited 2000-06-05 by lpd to treat empty MSINCDIR and LIBDIR specially.
23
 
24
# Set up linker differently for MSVC 4 vs. later versions
25
 
26
!if $(MSVC_VERSION) == 4
27
 
28
# MSVC version 4.x doesn't recognize the /QI0f switch, which works around
29
# an unspecified bug in the Pentium decoding of certain 0F instructions.
30
QI0f=
31
 
32
!else
33
#else $(MSVC_VERSION) != 4
34
 
35
# MSVC 5.x does recognize /QI0f.
36
QI0f=/QI0f
37
 
38
# Define separate CCAUX command-line switch that must be at END of line.
39
 
40
CCAUX_TAIL= /link
41
 
42
!endif
43
#endif #$(MSVC_VERSION) == 4
44
 
45
 
46
# Define the current directory prefix and shell invocations.
47
 
48
D=\#
49
 
50
SH=
51
 
52
# Define switches for the compilers.
53
 
54
C_=
55
O_=-Fo
56
RO_=$(O_)
57
 
58
# Define the arguments for genconf.
59
 
60
CONFILES=-p %%s
61
CONFLDTR=-ol
62
 
63
# Define the generic compilation flags.
64
 
65
PLATOPT=
66
 
67
INTASM=
68
PCFBASM=
69
 
70
# Make sure we get the right default target for make.
71
 
72
dosdefault: default
73
	@attrib -H dosdefault > nul:
74
	@echo Done. > dosdefault
75
	@attrib +H dosdefault
76
 
77
# Define the compilation flags.
78
 
79
# MSVC 8 (2005) warns about deprecated unsafe common functions like strcpy.
80
!if ($(MSVC_VERSION) == 8) || defined(WIN64)
81
VC8WARN=/wd4996 /wd4224
82
!else
83
VC8WARN=
84
!endif
85
 
86
!if ($(MSVC_VERSION) < 8)
87
CDCC=/Gi /ZI
88
!else
89
CDCC=/ZI
90
!endif
91
 
92
!if "$(CPU_FAMILY)"=="i386"
93
 
94
!if ($(MSVC_VERSION) >= 8) || defined(WIN64)
95
# MSVC 8 (2005) attempts to produce code good for all processors.
96
# and doesn't used /G5 or /GB.
97
# MSVC 8 (2005) avoids buggy 0F instructions.
98
CPFLAGS=
99
!else
100
!if $(CPU_TYPE)>500
101
CPFLAGS=/G5 $(QI0f)
102
!else if $(CPU_TYPE)>400
103
CPFLAGS=/GB $(QI0f)
104
!else
105
CPFLAGS=/GB $(QI0f)
106
!endif
107
!endif
108
 
109
!if $(FPU_TYPE)>0 && $(MSVC_VERSION)<5
110
FPFLAGS=/FPi87
111
!else
112
FPFLAGS=
113
!endif
114
 
115
!endif
116
 
117
!if "$(CPU_FAMILY)"=="ppc"
118
 
119
!if $(CPU_TYPE)>=620
120
CPFLAGS=/QP620
121
!else if $(CPU_TYPE)>=604
122
CPFLAGS=/QP604
123
!else
124
CPFLAGS=/QP601
125
!endif
126
 
127
FPFLAGS=
128
 
129
!endif
130
 
131
!if "$(CPU_FAMILY)"=="alpha"
132
 
133
# *** alpha *** This needs fixing
134
CPFLAGS=
135
FPFLAGS=
136
 
137
!endif
138
 
139
!if $(NOPRIVATE)!=0
140
CP=/DNOPRIVATE
141
!else
142
CP=
143
!endif
144
 
145
!if $(DEBUG)!=0
146
CD=/DDEBUG
147
!else
148
CD=
149
!endif
150
 
151
# Precompiled headers
152
!if $(MSVC_VERSION) >= 8
153
CPCH=/Fp$(GLOBJDIR)\gs.pch
154
!else
155
CPCH=/YX /Fp$(GLOBJDIR)\gs.pch
156
!endif
157
 
158
!if $(TDEBUG)!=0
159
# /Fd designates the directory for the .pdb file.
160
# Note that it must be followed by a space.
161
CT=/Od /Fd$(GLOBJDIR) $(NULL) $(CDCC) $(CPCH)
162
LCT=/DEBUG /INCREMENTAL:YES
163
COMPILE_FULL_OPTIMIZED=    # no optimization when debugging
164
COMPILE_WITH_FRAMES=    # no optimization when debugging
165
COMPILE_WITHOUT_FRAMES=    # no optimization when debugging
166
CMT=/MTd
167
!else
168
!if $(DEBUGSYM)==0
169
CT=
170
LCT=
171
CMT=/MT
172
!else
173
CT=/Zi /Fd$(GLOBJDIR) $(NULL)
174
LCT=/DEBUG
175
CMT=/MTd
176
!endif
177
!if $(MSVC_VERSION) == 5
178
# NOTE: With MSVC++ 5.0, /O2 produces a non-working executable.
179
# We believe the following list of optimizations works around this bug.
180
COMPILE_FULL_OPTIMIZED=/GF /Ot /Oi /Ob2 /Oy /Oa- /Ow-
181
!else
182
COMPILE_FULL_OPTIMIZED=/GF /O2 /Ob2
183
!endif
184
COMPILE_WITH_FRAMES=
185
COMPILE_WITHOUT_FRAMES=/Oy
186
!endif
187
 
188
!if $(MSVC_VERSION) >= 8
189
# MSVC 8 (2005) always does stack probes and checking.
190
CS=
191
!else
192
!if $(DEBUG)!=0 || $(TDEBUG)!=0
193
CS=/Ge
194
!else
195
CS=/Gs
196
!endif
197
!endif
198
 
199
!if ($(MSVC_VERSION) == 7) && defined(WIN64)
200
# Need to specify DDK include directories before .NET 2003 directories.
201
MSINCFLAGS=-I"$(INCDIR64A)" -I"$(INCDIR64B)"
202
!else
203
MSINCFLAGS=
204
!endif
205
 
206
# Specify output object name
207
CCOBJNAME=-Fo
208
 
209
# Specify function prolog type
210
COMPILE_FOR_DLL=
211
COMPILE_FOR_EXE=
212
COMPILE_FOR_CONSOLE_EXE=
213
 
214
# The /MT is for multi-threading.  We would like to make this an option,
215
# but it's too much work right now.
216
GENOPT=$(CP) $(CD) $(CT) $(CS) $(WARNOPT) $(VC8WARN) /nologo $(CMT)
217
 
218
CCFLAGS=$(PLATOPT) $(FPFLAGS) $(CPFLAGS) $(CFLAGS) $(XCFLAGS) $(MSINCFLAGS)
219
CC=$(COMP) /c $(CCFLAGS) @$(GLGENDIR)\ccf32.tr
220
CPP=$(COMPCPP) /c $(CCFLAGS) @$(GLGENDIR)\ccf32.tr
221
!if $(MAKEDLL)
222
WX=$(COMPILE_FOR_DLL)
223
!else
224
WX=$(COMPILE_FOR_EXE)
225
!endif
226
 
227
!if $(COMPILE_INITS)
228
ZM=/Zm600
229
!else
230
ZM=
231
!endif
232
 
233
 
234
# /Za disables the MS-specific extensions & enables ANSI mode.
235
CC_WX=$(CC) $(WX)
236
CC_=$(CC_WX) $(COMPILE_FULL_OPTIMIZED) /Za $(ZM)
237
CC_D=$(CC_WX) $(COMPILE_WITH_FRAMES)
238
CC_INT=$(CC_)
239
CC_NO_WARN=$(CC_)
240
 
241
# Compiler for auxiliary programs
242
 
243
CCAUX=$(COMPAUX) $(VC8WARN)
244
 
245
# Compiler for Windows programs.
246
CCWINFLAGS=$(COMPILE_FULL_OPTIMIZED)
247
 
248
#end msvccmd.mak