1226031Sstas########################################################################
2226031Sstas#
3226031Sstas# Copyright (c) 2009, 2010 Secure Endpoints Inc.
4226031Sstas# All rights reserved.
5226031Sstas# 
6226031Sstas# Redistribution and use in source and binary forms, with or without
7226031Sstas# modification, are permitted provided that the following conditions
8226031Sstas# are met:
9226031Sstas# 
10226031Sstas# - Redistributions of source code must retain the above copyright
11226031Sstas#   notice, this list of conditions and the following disclaimer.
12226031Sstas# 
13226031Sstas# - Redistributions in binary form must reproduce the above copyright
14226031Sstas#   notice, this list of conditions and the following disclaimer in
15226031Sstas#   the documentation and/or other materials provided with the
16226031Sstas#   distribution.
17226031Sstas# 
18226031Sstas# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19226031Sstas# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20226031Sstas# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
21226031Sstas# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
22226031Sstas# COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
23226031Sstas# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
24226031Sstas# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25226031Sstas# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26226031Sstas# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27226031Sstas# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
28226031Sstas# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29226031Sstas# POSSIBILITY OF SUCH DAMAGE.
30226031Sstas# 
31226031Sstas
32226031SstasRELDIR = lib\heimdal
33226031Sstas
34226031Sstas!include ../../windows/NTMakefile.w32
35226031Sstas
36226031Sstas!ifndef STATICLIBS
37226031Sstas
38226031SstasDLLDEPS= \
39226031Sstas	$(LIBASN1)	\
40226031Sstas	$(LIBCOMERR)	\
41226031Sstas	$(LIBHCRYPTO)	\
42226031Sstas	$(LIBHX509)	\
43226031Sstas	$(LIBKRB5)	\
44226031Sstas	$(LIBROKEN)	\
45226031Sstas	$(LIBSQLITE)	\
46226031Sstas	$(LIBWIND)	\
47226031Sstas	$(LIBLTM)	\
48226031Sstas	$(LIBHEIMBASE)
49226031Sstas
50226031SstasDLLSDKDEPS= \
51226031Sstas	$(PTHREAD_LIB)	\
52226031Sstas	secur32.lib	\
53226031Sstas	shell32.lib	\
54226128Sstas	dnsapi.lib      \
55226128Sstas        shlwapi.lib
56226031Sstas
57226031SstasDEF=$(OBJ)\heimdal.def
58226031Sstas
59226031SstasRES=$(OBJ)\heimdal-version.res
60226031Sstas
61226031SstasDEFSRC= ..\asn1\libasn1-exports.def \
62226031Sstas	..\wind\libwind-exports.def \
63226031Sstas	..\hcrypto\libhcrypto-exports.def \
64226031Sstas	..\hx509\libhx509-exports.def \
65226031Sstas	$(OBJDIR)\lib\krb5\libkrb5-exports.def
66226031Sstas
67226031Sstas$(DEF): $(DEFSRC)
68226031Sstas	copy $(DEFSRC:  = + ) $(DEF)
69226031Sstas
70226031SstasDLL=$(BINDIR)\heimdal.dll
71226031Sstas
72226031Sstas$(LIBHEIMDAL): $(BINDIR)\heimdal.dll
73226031Sstas
74226031Sstas$(DLL): $(DLLDEPS) $(DEF) $(RES)
75226031Sstas	$(DLLGUILINK_C) $(DLLDEPS) $(DLLSDKDEPS) $(RES) \
76226031Sstas		-def:$(DEF) -out:$(DLL) \
77226031Sstas		-implib:$(LIBHEIMDAL)
78226031Sstas	$(DLLPREP_NODIST)
79226031Sstas
80226031Sstasclean::
81226031Sstas	-$(RM) $(BINDIR)\heimdal.*
82226031Sstas
83226031Sstas!else
84226031Sstas
85226031Sstas$(LIBHEIMDAL): $(LIBASN1) $(LIBWIND) $(LIBHCRYPTO) $(LIBHX509) $(LIBKRB5) $(LIBHEIMBASE)
86226031Sstas	$(LIBCON)
87226031Sstas
88226031Sstas!endif
89226031Sstas
90226031Sstasall:: $(LIBHEIMDAL)
91226031Sstas
92226031Sstasclean::
93226031Sstas	-$(RM) $(LIBHEIMDAL)
94