source: gsdl/trunk/lib/win32.mak@ 15580

Last change on this file since 15580 was 15580, checked in by mdewsnip, 16 years ago

Hopefully the last of the makefile tidy ups.

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 2.8 KB
Line 
1###########################################################################
2#
3# win32 makefile -- lib
4# A component of the Greenstone digital library software
5# from the New Zealand Digital Library Project at the
6# University of Waikato, New Zealand.
7#
8# Copyright (C) 1999-2008 The New Zealand Digital Library Project
9#
10#
11# This program is free software; you can redistribute it and/or modify
12# it under the terms of the GNU General Public License as published by
13# the Free Software Foundation; either version 2 of the License, or
14# (at your option) any later version.
15#
16# This program is distributed in the hope that it will be useful,
17# but WITHOUT ANY WARRANTY; without even the implied warranty of
18# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19# GNU General Public License for more details.
20#
21# You should have received a copy of the GNU General Public License
22# along with this program; if not, write to the Free Software
23# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
24#
25###########################################################################
26
27GSDL_DIR = ..
28INDEXERS_DIR = $(GSDL_DIR)\indexers
29PACKAGES_DIR = $(GSDL_DIR)\packages
30
31
32GSDL_VC4 = 0
33LOCAL_LIBRARY = 0
34DLL = 0
35DLLDEBUG = 0
36STLPATH = "$(PACKAGES_DIR)\windows\stlport\stlport"
37
38
39!IF $(GSDL_VC4)
40CPPFLAGS = -GX
41!ELSE
42CPPFLAGS = -EHsc
43!ENDIF
44
45!IF $(DLL)
46CPPFLAGS = $(CPPFLAGS) -MD
47!ELSE
48!IF ($(DLLDEBUG))
49CPPFLAGS = $(CPPFLAGS) -MDd
50!ENDIF
51!ENDIF
52
53
54AR = lib
55CC = cl
56DEFS = -D__WIN32__ -DHAVE_CONFIG_H -DPARADOCNUM -D_LITTLE_ENDIAN \
57 -DSHORT_SUFFIX -D_CRT_SECURE_NO_DEPRECATE
58INCLUDES = -I"$(GSDL_DIR)" -I"$(INDEXERS_DIR)\mg\lib" -I"$(PACKAGES_DIR)\windows\gdbm\gdbm"
59
60!IF $(GSDL_VC4)
61DEFS = $(DEFS) -DGSDL_NAMESPACE_BROKEN -DGSDL_USE_IOS_H -D__STL_NO_NEW_IOSTREAMS
62INCLUDES = $(INCLUDES) -I$(STLPATH)
63!ENDIF
64!IF $(LOCAL_LIBRARY)
65DEFS = $(DEFS) -DGSDL_LOCAL_LIBRARY
66!ENDIF
67
68
69COMPILE = $(CC) -nologo -c $(CPPFLAGS) $(DEFS) $(INCLUDES)
70
71
72.SUFFIXES:
73.SUFFIXES: .cpp .obj
74.cpp.obj:
75 $(COMPILE) $<
76
77
78SOURCES = \
79 cfgread.cpp \
80 cnfgable.cpp \
81 cnfgator.cpp \
82 dbclass.cpp \
83 display.cpp \
84 fileutil.cpp \
85 gdbmclass.cpp \
86 gsdlsitecfg.cpp \
87 gsdltimes.cpp \
88 gsdltools.cpp \
89 gsdlunicode.cpp \
90 infodbclass.cpp \
91 md5.cpp \
92 OIDtools.cpp \
93 phrases.cpp \
94 text_t.cpp
95
96OBJECTS = \
97 cfgread.obj \
98 cnfgable.obj \
99 cnfgator.obj \
100 dbclass.obj \
101 display.obj \
102 fileutil.obj \
103 gdbmclass.obj \
104 gsdlsitecfg.obj \
105 gsdltimes.obj \
106 gsdltools.obj \
107 gsdlunicode.obj \
108 infodbclass.obj \
109 md5.obj \
110 OIDtools.obj \
111 phrases.obj \
112 text_t.obj
113
114LIBRARY = gsdllib.lib
115
116
117# Default target: make gsdllib.lib
118all: $(LIBRARY)
119
120gsdllib.lib : $(OBJECTS)
121 if EXIST $(LIBRARY) del $(LIBRARY)
122 $(AR) -nologo /out:$(LIBRARY) $(OBJECTS)
123
124install:
125
126clean:
127 del *.obj
128 del $(LIBRARY)
129
130
131# Always recompile gsdltools in case GSDL_LOCAL_LIBRARY has changed
132gsdltools.obj: FORCE
133
134FORCE:
Note: See TracBrowser for help on using the repository browser.