root/main/trunk/greenstone2/runtime-src/win32.mak @ 22078

Revision 21435, 3.3 KB (checked in by ak19, 10 years ago)

Better way of setting the ENABLE_indexer and USE_SQLITE and ENABLE_JNI variables in the windows makefiles.

Line 
1###########################################################################
2#
3# win32 makefile -- gsdl runtime code
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  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
27GSDLHOME = $(GSDLHOME)
28RUNTIMEHOME = $(MAKEDIR)
29
30GSDL_VC4 = 0
31LOCAL_LIBRARY = 0
32APACHE_HTTPD = 0
33DEBUG = 0
34DLL = 0
35DLLDEBUG = 0
36USE_SQLITE = 1
37USE_MSSQL = 0
38USE_Z3950 = 0
39ENABLE_MG = 1
40ENABLE_MGPP = 1
41ENABLE_LUCENE = 1
42
43MDEFINES = /f win32.mak
44
45COMPILEDIRS = src\colservr src\protocol
46
47INSTALLDIRS = src\recpt src\oaiservr
48
49PACKAGEDIRS =
50
51YAZ_DIR = packages\yaz\yaz-2.1.4\win
52
53MAKECMD = $(MAKE) $(MDEFINES) GSDLHOME="$(GSDLHOME)"
54!IF $(GSDL_VC4)
55MAKECMD = $(MAKECMD) GSDL_VC4=1
56!ENDIF
57!IF $(LOCAL_LIBRARY)
58MAKECMD = $(MAKECMD) LOCAL_LIBRARY=1
59INSTALLDIRS = $(INSTALLDIRS) src\w32server
60!ENDIF
61!IF $(APACHE_HTTPD)
62MAKECMD = $(MAKECMD) APACHE_HTTPD=1
63INSTALLDIRS = $(INSTALLDIRS) src\w32apachectl packages\apache-httpd
64!ENDIF
65!IF $(DEBUG)
66MAKECMD = $(MAKECMD) DEBUG=1
67!ENDIF
68!IF $(DLL)
69MAKECMD = $(MAKECMD) DLL=1
70!ENDIF
71!IF $(DLLDEBUG)
72MAKECMD = $(MAKECMD) DLLDEBUG=1
73!ENDIF
74!IF !$(USE_SQLITE)
75MAKECMD = $(MAKECMD) USE_SQLITE=0
76!ENDIF
77!IF $(USE_MSSQL)
78MAKECMD = $(MAKECMD) USE_MSSQL=1
79!ENDIF
80!IF $(USE_Z3950)
81MAKECMD = $(MAKECMD) USE_Z3950=1
82INSTALLDIRS = src\z3950 $(INSTALLDIRS)
83PACKAGEDIRS = $(PACKAGEDIRS) packages\d2m $(YAZ_DIR)
84!ENDIF
85!IF !$(ENABLE_MG)
86MAKECMD = $(MAKECMD) ENABLE_MG=0
87!ENDIF
88!IF !$(ENABLE_MGPP)
89MAKECMD = $(MAKECMD) ENABLE_MGPP=0
90!ENDIF
91!IF !$(ENABLE_LUCENE)
92MAKECMD = $(MAKECMD) ENABLE_LUCENE=0
93!ENDIF
94
95MAKECLEANCMD = $(MAKE) $(MDEFINES) GSDLHOME="$(GSDLHOME)" clean
96
97all: win32.mak $(PACKAGEDIRS) $(COMPILEDIRS) $(INSTALLDIRS)
98
99install: win32.mak $(INSTALLDIRS)   
100    if not exist "$(GSDLHOME)\etc\logs-gsi\*.*" MD "$(GSDLHOME)\etc\logs-gsi"
101clean:
102    cd "$(RUNTIMEHOME)"
103    cd src\colservr
104    $(MAKECLEANCMD)
105    cd "$(RUNTIMEHOME)"
106    cd src\protocol
107    $(MAKECLEANCMD)
108    cd "$(RUNTIMEHOME)"
109    cd src\recpt
110    $(MAKECLEANCMD)
111    cd "$(RUNTIMEHOME)"
112    cd src\oaiservr
113    $(MAKECLEANCMD)
114    cd "$(RUNTIMEHOME)"
115    cd src\w32server
116    $(MAKECLEANCMD)
117    cd "$(RUNTIMEHOME)"
118    cd src\w32apachectl
119    $(MAKECLEANCMD)
120    cd "$(RUNTIMEHOME)"
121    cd packages\apache-httpd
122    $(MAKECLEANCMD)
123    cd "$(GSDLHOME)"
124
125$(COMPILEDIRS): FORCE
126    cd "$(RUNTIMEHOME)"
127    cd "$@"
128    $(MAKECMD)
129    cd "$(GSDLHOME)"
130
131$(INSTALLDIRS): FORCE
132    cd "$(RUNTIMEHOME)"
133    cd "$@"
134    $(MAKECMD)
135    $(MAKECMD) install
136    cd "$(GSDLHOME)"
137
138$(YAZ_DIR): FORCE
139    cd "$@"
140    nmake HAVE_ICONV=0 HAVE_LIBXML2=0
141    cd "$(GSDLHOME)"
142
143FORCE:
144
Note: See TracBrowser for help on using the browser.