GSS_S_PROMPTING_NEEDED is a bit
[cyrus-sasl.git] / utils / NTMakefile
1 !INCLUDE ..\win32\common.mak
2
3 sasl_apps=saslpasswd2.exe sasldblistusers2.exe testsuite.exe pluginviewer.exe
4 sasl_out=saslpasswd2.pdb sasldblistusers2.pdb testsuite.pdb pluginviewer.pdb
5
6 saslpwd_objs = saslpasswd.obj
7 sasldblistusers_objs = sasldblistusers.obj
8 testsuite_objs = testsuite.obj
9 pluginviewer_objs = pluginviewer.obj
10
11 all_objs = $(saslpwd_objs) $(sasldblistusers_objs) $(testsuite_objs) $(pluginviewer_objs)
12 all_out = $(sasl_apps) $(sasl_out)
13
14 DB_FLAGS = /I $(DB_INCLUDE) /I "..\sasldb"
15 CPPFLAGS = /I "..\win32\include" /I "." /I "..\include" $(DB_FLAGS) /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL"
16 CPPFLAGS = $(CPPFLAGS) /DNEED_GETOPT
17
18
19 DB_LIBS=/libpath:$(DB_LIBPATH) $(DB_LIB)
20 SASL_LIB=/libpath:"..\lib" libsasl.lib
21 SASL_DB_LIB=/libpath:"..\plugins" saslSASLDB.lib
22
23 # EXTRA_LIBS is automatically included into LINK32EXE_FLAGS/LINK32DLL_FLAGS
24 EXTRA_LIBS=$(SASL_LIB) 
25
26 # Where to install files from this directory
27 bindir = $(prefix)\bin
28
29
30 all : all-recursive
31
32 #
33 # /I flag to xcopy tells to treat the last parameter as directory and create all missing levels
34 #
35 # In order to force xcopy not to confirm if the second parameter is file or directory,
36 # the first parameter has to contain a wildcard character. For example, we use libsasl.l*,
37 # instead of libsasl.lib. Ugly, but works!
38 #
39 # Note, that we will copy all executabless here, not just $(sasl_apps). This is a bug, but it allows
40 # us to copy optionally built executables, which might not be in $(sasl_apps). The latter is a feature.
41 #
42 install: $(sasl_apps)
43         @xcopy *.exe $(bindir) /I /F /Y
44
45 all-recursive : $(sasl_apps)
46
47 saslpasswd2.exe: $(saslpwd_objs)
48         $(LINK32EXE) @<< $(LINK32EXE_FLAGS) /pdb:"saslpasswd2.pdb" /out:"saslpasswd2.exe" $(saslpwd_objs)
49 <<
50
51 sasldblistusers2.exe: $(sasldblistusers_objs)
52         $(LINK32EXE) @<< $(LINK32EXE_FLAGS) $(SASL_DB_LIB) /pdb:"sasldblistusers2.pdb" /out:"sasldblistusers2.exe" $(sasldblistusers_objs)
53 <<
54
55 testsuite.exe: $(testsuite_objs)
56         $(LINK32EXE) @<< $(LINK32EXE_FLAGS) /pdb:"testsuite.pdb" /out:"testsuite.exe" $(testsuite_objs)
57 <<
58
59 pluginviewer.exe: $(pluginviewer_objs)
60         $(LINK32EXE) @<< $(LINK32EXE_FLAGS) /pdb:"pluginviewer.pdb" /out:"pluginviewer.exe" $(pluginviewer_objs)
61 <<
62
63 CLEAN :
64         -@erase $(all_objs)
65         -@erase "*.idb"
66         -@erase "*.pch"
67         -@erase "*.pdb"
68         -@erase $(all_out)
69
70 .c.obj::
71    $(CPP) @<<
72    $(CPP_PROJ) $< 
73 <<
74
75 .cpp.obj::
76    $(CPP) @<<
77    $(CPP_PROJ) $< 
78 <<
79
80 .cxx.obj::
81    $(CPP) @<<
82    $(CPP_PROJ) $< 
83 <<