~ubuntu-branches/ubuntu/oneiric/likewise-open/oneiric

« back to all changes in this revision

Viewing changes to krb5/src/windows/identity/config/Makefile.w32

  • Committer: Bazaar Package Importer
  • Author(s): Scott Salley
  • Date: 2010-11-22 12:06:00 UTC
  • mfrom: (1.1.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20101122120600-8lba1fpceot71wlb
Tags: 6.0.0.53010-1
Likewise Open 6.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
#  Khimaira : Win32 configuration makefile
 
3
#             This file will be included by all the makefiles
 
4
#             in the build tree.
 
5
#
 
6
# Copyright (c) 2004,2005,2006 Massachusetts Institute of Technology
 
7
# Copyright (c) 2006,2007 Secure Endpoints Inc.
 
8
#
 
9
# Permission is hereby granted, free of charge, to any person
 
10
# obtaining a copy of this software and associated documentation files
 
11
# (the "Software"), to deal in the Software without restriction,
 
12
# including without limitation the rights to use, copy, modify, merge,
 
13
# publish, distribute, sublicense, and/or sell copies of the Software,
 
14
# and to permit persons to whom the Software is furnished to do so,
 
15
# subject to the following conditions:
 
16
#
 
17
# The above copyright notice and this permission notice shall be
 
18
# included in all copies or substantial portions of the Software.
 
19
#
 
20
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 
21
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 
22
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
 
23
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
 
24
# BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 
25
# ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 
26
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 
27
# SOFTWARE.
 
28
 
 
29
!ifndef KHIMAIRA_WIN32_CONFIG
 
30
KHIMAIRA_WIN32_CONFIG=1
 
31
 
 
32
# Environment Variables
 
33
#  The following environment variables MUST be set:
 
34
#   KH_ROOT : Root of the source tree.
 
35
#   KH_BUILD: One of DEBUG or RETAIL
 
36
#
 
37
#  The following environment variables are optional:
 
38
#   KH_RUNTIME: One of STATIC or DLL, specifies whether the CRT libs
 
39
#               are linked statically or through MSVCRT.DLL.
 
40
#   KH_AUXCFLAGS: Optional flags for CL
 
41
#   KH_RELEASE: Release type.  One of OFFICIAL, PRERELEASE, PRIVATE or SPECIAL.
 
42
#      OFFICIAL   : An official release of Khimaira
 
43
#      PREPRELEASE: A beta/release candidate release
 
44
#      PRIVATE    : Private build
 
45
#      SPECIAL    : Special build.  Typically one with non-mainline patches.
 
46
 
 
47
# Version info
 
48
NETIDMGR_VERSION_MAJOR=1
 
49
NETIDMGR_VERSION_MINOR=3
 
50
NETIDMGR_VERSION_PATCH=1
 
51
NETIDMGR_VERSION_AUX=0
 
52
NETIDMGR_RELEASEDESC=
 
53
 
 
54
# The API version.  This number must be incremented each time the API
 
55
# changes.  Plugins specify the version of the API that they were
 
56
# compiled against and the Module Manager uses the API numbers to
 
57
# decide whether the plugin is safe to load or not.
 
58
#
 
59
# Changes to the API version numbers should be documented in
 
60
# apiversion.txt at the root of the source tree.
 
61
NETIDMGR_VERSION_API=10
 
62
 
 
63
# Minimum backwards compatible version.  API versions from
 
64
# NETIDMGR_VERSION_API_MINCOMPAT through NETIDMGR_VERSION_API
 
65
# inclusive, are compatible with this version.
 
66
NETIDMGR_VERSION_API_MINCOMPAT=5
 
67
 
 
68
NETIDMGR_VERSION=$(NETIDMGR_VERSION_MAJOR).$(NETIDMGR_VERSION_MINOR).$(NETIDMGR_VERSION_PATCH).$(NETIDMGR_VERSION_AUX)
 
69
NETIDMGR_VERSIONC=$(NETIDMGR_VERSION_MAJOR),$(NETIDMGR_VERSION_MINOR),$(NETIDMGR_VERSION_PATCH),$(NETIDMGR_VERSION_AUX)
 
70
 
 
71
# Source information
 
72
NETIDMGR_SRC_COMPANY_1033=Massachusetts Institute of Technology
 
73
NETIDMGR_SRC_COPYRIGHT_1033=(C) 2005-2007 Massachusetts Institute of Technology
 
74
 
 
75
# Choose the default build type if one is not set
 
76
!if ("$(KH_BUILD)" != "DEBUG") && ("$(KH_BUILD)" != "RETAIL")
 
77
!  if defined(NODEBUG) && "$(NODEBUG)"=="1"
 
78
KH_BUILD=RETAIL
 
79
!  else
 
80
KH_BUILD=DEBUG
 
81
!  endif
 
82
!endif
 
83
 
 
84
!if "$(KH_BUILD)"=="DEBUG" && defined(NODEBUG) && "$(NODEBUG)"=="1"
 
85
! error The Khimaira build configuration is set for DEBUG while the Platform SDK build environment is set to RETAIL.
 
86
!endif
 
87
 
 
88
# The default release type is PRIVATE is no other type is specified
 
89
!if ("$(KH_RELEASE)" != "OFFICIAL") && ("$(KH_RELEASE)" != "PRERELEASE") && ("$(KH_RELEASE)" != "PRIVATE") && ("$(KH_RELEASE)" != "SPECIAL")
 
90
KH_RELEASE=PRIVATE
 
91
!endif
 
92
 
 
93
# Actual build environment settings
 
94
 
 
95
# See what compiler we are using
 
96
# TODO: Update this to support other compilers
 
97
!if defined(MSVCVer) && "$(MSVCVer)"=="8.0"
 
98
KH_CLVER=vc8
 
99
!else
 
100
KH_CLVER=vc7
 
101
!endif
 
102
 
 
103
# Check for required env vars
 
104
!ifndef MODULE
 
105
!       error MODULE must be specified
 
106
!endif
 
107
!ifndef KH_ROOT
 
108
! ifndef PISMERE
 
109
!   error Either KH_ROOT or PISMERE must be defined
 
110
! else
 
111
KH_ROOT=$(PISMERE)\athena\auth\krb5\src\windows\identity
 
112
! endif
 
113
!endif
 
114
 
 
115
!ifdef NODEBUG
 
116
OUTPRE_DBG=rel
 
117
!else
 
118
OUTPRE_DBG=dbg
 
119
!endif
 
120
OUTPRE1=obj
 
121
OUTPRE2=$(OUTPRE1)\$(CPU)
 
122
OUTPRE3=$(OUTPRE2)\$(OUTPRE_DBG)
 
123
OUTPRE=$(OUTPRE3)^\
 
124
 
 
125
 
 
126
 
 
127
# Output directory structure
 
128
DESTROOT=$(KH_ROOT)\obj
 
129
OBJROOT=$(KH_ROOT)\obj
 
130
SRC=$(KH_ROOT)
 
131
 
 
132
DESTDIR=$(DESTROOT)\$(CPU)\$(OUTPRE_DBG)
 
133
OBJDIR=$(OBJROOT)\$(CPU)\$(OUTPRE_DBG)
 
134
 
 
135
OBJ=$(OBJDIR)\$(MODULE)
 
136
INCDIR=$(DESTDIR)\inc
 
137
#BINDIR=$(DESTDIR)\bin
 
138
BINDIR=$(KH_ROOT)\$(OUTPRE)
 
139
#LIBDIR=$(DESTDIR)\lib
 
140
LIBDIR=$(KH_ROOT)\$(OUTPRE)
 
141
DOCDIR=$(DESTDIR)\doc
 
142
 
 
143
# Source directories
 
144
CONFDIR=$(SRC)\config
 
145
 
 
146
# If we are forcing a Win2K build, we need to adjust the build
 
147
# directories and environment.
 
148
 
 
149
!ifdef KHBUILD_W2K
 
150
 
 
151
OBJ=$(OBJ)\W2K
 
152
BINDIR=$(BINDIR)\W2K
 
153
LIBDIR=$(LIBDIR)\W2K
 
154
 
 
155
APPVER=5.0
 
156
TARGETOS=WINNT
 
157
_WIN32_IE=0x0500
 
158
_WIN32_WINNT=0x0500
 
159
 
 
160
!endif
 
161
 
 
162
# Setup environment for win32.mak
 
163
 
 
164
!if "$(KH_BUILD)" == "RETAIL"
 
165
NODEBUG=1
 
166
!endif
 
167
 
 
168
# Win32.mak
 
169
 
 
170
!include <Win32.Mak>
 
171
 
 
172
# Program macros
 
173
 
 
174
CD=cd
 
175
RM=del /q
 
176
MKDIR=md
 
177
RMDIR=rd
 
178
ECHO=echo
 
179
MAKECMD=nmake /nologo
 
180
CP=copy /y
 
181
LINK=link
 
182
CCSV=perl $(SRC)\config\ccsv.pl
 
183
MC=mc
 
184
 
 
185
!ifdef KH_DOXYFULLPATH
 
186
DOXYGEN=$(KH_DOXYFULLPATH)
 
187
!else
 
188
DOXYGEN=doxygen
 
189
!endif
 
190
 
 
191
!ifdef KH_HHCFULLPATH
 
192
HHC=$(KH_HHCFULLPATH)
 
193
!else
 
194
HHC=hhc
 
195
!endif
 
196
 
 
197
!ifdef KH_KFWPATH
 
198
KFWINCDIR=$(KH_KFWPATH)\inc
 
199
kfwincflags = -I$(KFWINCDIR)\krb5 -I$(KFWINCDIR)\krb5\KerberosIV -I$(KFWINCDIR)\krb4 -I$(KFWINCDIR)\loadfuncs -I$(KFWINCDIR)
 
200
KFWLIBDIR=$(KH_KFWPATH)\lib\$(CPU)
 
201
!else if defined(PISMERE)
 
202
KFWINCDIR=$(PISMERE)\athena\auth\krb5\src\include
 
203
kfwincflags = -I$(KFWINCDIR) -I$(PISMERE)\athena\util\loadfuncs -I$(PISMERE)\athena\auth\krb5\src\include\kerberosIV -I$(PISMERE)\athena\auth\krb4\include
 
204
KFWLIBDIR=$(PISMERE)\target\lib\$(CPU)\$(OUTPRE_DBG)
 
205
!endif
 
206
 
 
207
!ifdef KH_AFSPATH
 
208
AFSINCDIR=$(KH_AFSPATH)\include
 
209
AFSLIBDIR=$(KH_AFSPATH)\lib
 
210
afsincflags=-I$(AFSINCDIR)
 
211
!endif
 
212
 
 
213
#EXTLIBDIR=$(SRC)\ext-lib\$(CPU)
 
214
#EXTINCDIR=-I$(SRC)\ext-inc
 
215
 
 
216
incflags= -I$(INCDIR) -I$(SRC)\include -I. -I$(OBJ) $(kfwincflags) $(afsincflags)
 
217
rincflags= /i $(INCDIR) /i $(SRC)\include /i .
 
218
khdefines=-DUNICODE -D_UNICODE
 
219
khcwarn=/Wp64
 
220
!ifndef KH_NO_WX
 
221
khcwarn=$(khcwarn) /WX
 
222
!endif
 
223
 
 
224
!if "$(CPU)" == "i386"
 
225
khdefines=$(khdefines) -D_USE_32BIT_TIME_T
 
226
!endif
 
227
 
 
228
#DEBUG_SYMBOLS
 
229
ldebug=$(ldebug) /DEBUG
 
230
cdebug=$(cdebug) -Os -Zi
 
231
 
 
232
# Additionally, suppress conflicting default library directives that we
 
233
# might pull in from external libraries.
 
234
 
 
235
!ifndef NODEBUG
 
236
lndeflibflag=/NODEFAULTLIB:MSVCRT
 
237
!else
 
238
lndeflibflag=/NODEFAULTLIB:MSVCRTD
 
239
!endif
 
240
 
 
241
khcflags=$(cdebug) $(cflags) $(incflags) $(khdefines) $(khcwarn)
 
242
khlguiflags=$(ldebug) $(guilflags) $(lndeflibflag)
 
243
khlconflags=$(ldebug) $(conlflags) $(lndeflibflag)
 
244
khldllguiflags=$(ldebug) $(dlllflags) $(lndeflibflag)
 
245
khldllconflags=$(ldebug) $(dlllflags) $(lndeflibflag)
 
246
 
 
247
!if "$(KH_RUNTIME)" == "STATIC"
 
248
khcflags=$(khcflags) $(cvarsmt)
 
249
khlguiflags=$(khlguiflags) $(guilibsmt)
 
250
khlconflags=$(khlconflags) $(conlibsmt)
 
251
khldllguiflags=$(khldllguiflags) $(guilibsmt)
 
252
khldllconflags=$(khldllconflags) $(conlibsmt)
 
253
!else
 
254
khcflags=$(khcflags) $(cvarsdll)
 
255
khlguiflags=$(khlguiflags) $(guilibsdll)
 
256
khlconflags=$(khlconflags) $(conlibsdll)
 
257
khldllguiflags=$(khldllguiflags) $(guilibsdll)
 
258
khldllconflags=$(khldllconflags) $(conlibsdll)
 
259
!endif
 
260
 
 
261
C2OBJ=$(CC) $(khcflags) $(KH_AUXCFLAGS) /Fo"$@" /c $**
 
262
 
 
263
EXECONLINK=$(LINK) /NOLOGO $(khlconflags) /OUT:$@ $**
 
264
 
 
265
EXEGUILINK=$(LINK) /NOLOGO $(khlguiflags) /OUT:$@ $**
 
266
 
 
267
DLLCONLINK=$(LINK) /NOLOGO $(khldllconflags) /OUT:$@ /IMPLIB:$(LIBDIR)\$(@B).lib $**
 
268
 
 
269
DLLGUILINK=$(LINK) /NOLOGO $(khldllguiflags) /OUT:$@ /IMPLIB:$(LIBDIR)\$(@B).lib $**
 
270
 
 
271
DLLRESLINK=$(LINK) /NOLOGO /DLL /NOENTRY /MACHINE:$(PROCESSOR_ARCHITECTURE) /OUT:$@ $**
 
272
 
 
273
RC2RES=$(RC) $(RFLAGS) $(rincflags) /fo $@ $**
 
274
 
 
275
MC2RC=$(MC) $(MCFLAGS) -h $(OBJ)\ -m 1024 -r $(OBJ)\ -x $(OBJ)\ $**
 
276
 
 
277
{}.c{$(OBJ)}.obj:
 
278
        $(C2OBJ)
 
279
 
 
280
{$(OBJ)}.c{$(OBJ)}.obj:
 
281
        $(C2OBJ)
 
282
 
 
283
{}.h{$(INCDIR)}.h:
 
284
        $(CP) $** $@
 
285
 
 
286
{}.rc{$(OBJ)}.res:
 
287
        $(RC2RES)
 
288
 
 
289
{$(OBJ)}.rc{$(OBJ)}.res:
 
290
        $(RC2RES)
 
291
 
 
292
clean::
 
293
        if exist "$(OBJ)" $(RM) "$(OBJ)"
 
294
        if exist vc70.pdb  $(RM) vc70.pdb
 
295
        if exist vc80.pdb  $(RM) vc80.pdb
 
296
 
 
297
test::
 
298
 
 
299
mkdirs::
 
300
!if !exist($(OBJ))
 
301
        $(MKDIR) $(OBJ)
 
302
!endif
 
303
 
 
304
TAGFILE = $(SRC)\TAGS
 
305
 
 
306
etag::
 
307
        etags -o $(TAGFILE) -a *.c *.h
 
308
 
 
309
.SUFFIXES: .h
 
310
 
 
311
#
 
312
# Manifest handling
 
313
#
 
314
# Starting with Visual Studio 8, the C compiler and the linker
 
315
# generate manifests so that the applications will link with the
 
316
# correct side-by-side DLLs at run-time.  These are required for
 
317
# correct operation under Windows XP.  We also have custom manifests
 
318
# which need to be merged with the manifests that VS creates.
 
319
#
 
320
# The syntax for invoking the _VC_MANIFEST_EMBED_foo macro is:
 
321
# $(_VC_MANIFEST_EMBED_???) <any additional manifests that need to be merged in>
 
322
#
 
323
 
 
324
!ifndef MT
 
325
MT=mt.exe -nologo
 
326
!endif
 
327
 
 
328
_VC_MANIFEST_EMBED_EXE= \
 
329
if exist $@.manifest $(MT) -outputresource:$@;1 -manifest $@.manifest
 
330
 
 
331
_VC_MANIFEST_EMBED_DLL= \
 
332
if exist $@.manifest $(MT) -outputresource:$@;2 -manifest $@.manifest
 
333
 
 
334
# Note that if you are merging manifests, then the VS generated
 
335
# manifest should be cleaned up after calling _VC_MANIFEST_EMBED_???.
 
336
# This ensures that even if the DLL or EXE is executed in-place, the
 
337
# embedded manifest will be used.  Otherwise the $@.manifest file will
 
338
# be used.
 
339
_VC_MANIFEST_CLEAN= \
 
340
if exist $@.manifest $(RM) $@.manifest
 
341
 
 
342
# End of manifest handling
 
343
 
 
344
!endif