1 | ###########################################################################
|
---|
2 | #
|
---|
3 | # Makefile -- src/oaiservr
|
---|
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 |
|
---|
27 | GSDL_DIR = ../..
|
---|
28 | INDEXERS_DIR = $(GSDL_DIR)/indexers
|
---|
29 | COLSERVR_DIR = $(GSDL_DIR)/src/colservr
|
---|
30 | PROTOCOL_DIR = $(GSDL_DIR)/src/protocol
|
---|
31 | RECPT_DIR = $(GSDL_DIR)/src/recpt
|
---|
32 |
|
---|
33 |
|
---|
34 | ENABLE_ACCENTFOLD = @ENABLE_ACCENTFOLD@
|
---|
35 | ifeq ($(ENABLE_ACCENTFOLD), 1)
|
---|
36 | ACCENTFOLD_LIBS = $(INDEXERS_DIR)/packages/unac/libunac.a
|
---|
37 | else
|
---|
38 | ACCENTFOLD_LIBS =
|
---|
39 | endif
|
---|
40 |
|
---|
41 |
|
---|
42 | CPP = @CXX@
|
---|
43 | CPPFLAGS = @CXXFLAGS@
|
---|
44 | INCLUDES = -I$(GSDL_DIR)/lib -I$(COLSERVR_DIR) -I$(PROTOCOL_DIR) -I$(RECPT_DIR) -I$(INDEXERS_DIR)/mgpp/text
|
---|
45 | LDFLAGS = @LDFLAGS@
|
---|
46 | LIBS = @LIBS@ @GDBM_LIBPATH@ -lgdbm -L$(GSDL_DIR)/packages/expat/lib -lexpat $(ACCENTFOLD_LIBS)
|
---|
47 | INSTALL = @INSTALL@
|
---|
48 |
|
---|
49 |
|
---|
50 | CPPCOMPILE = $(CPP) -c $(CPPFLAGS) $(INCLUDES)
|
---|
51 | CPPLINK = $(CPP) $(LDFLAGS) -o $@
|
---|
52 |
|
---|
53 |
|
---|
54 | .SUFFIXES:
|
---|
55 | .SUFFIXES: .cpp .o
|
---|
56 | .cpp.o:
|
---|
57 | $(CPPCOMPILE) -o $@ $<
|
---|
58 |
|
---|
59 |
|
---|
60 | RECPT_OBJECTS = \
|
---|
61 | $(RECPT_DIR)/cgiargs.o \
|
---|
62 | $(RECPT_DIR)/cgiutils.o \
|
---|
63 | $(RECPT_DIR)/htmlutils.o \
|
---|
64 | $(RECPT_DIR)/recptprototools.o
|
---|
65 |
|
---|
66 | SOURCES = \
|
---|
67 | abstractlistaction.cpp \
|
---|
68 | dublincore.cpp \
|
---|
69 | identityaction.cpp \
|
---|
70 | listidsaction.cpp \
|
---|
71 | listrecsaction.cpp \
|
---|
72 | listsetsaction.cpp \
|
---|
73 | metaformat.cpp \
|
---|
74 | metaformatsaction.cpp \
|
---|
75 | oaiaction.cpp \
|
---|
76 | oaiargs.cpp \
|
---|
77 | oaiconfig.cpp \
|
---|
78 | oaidispatcher.cpp \
|
---|
79 | oaimain.cpp \
|
---|
80 | oaitools.cpp \
|
---|
81 | recordaction.cpp \
|
---|
82 | resumptiontoken.cpp \
|
---|
83 | rfc1807.cpp
|
---|
84 |
|
---|
85 | OBJECTS = \
|
---|
86 | abstractlistaction.o \
|
---|
87 | dublincore.o \
|
---|
88 | identityaction.o \
|
---|
89 | listidsaction.o \
|
---|
90 | listrecsaction.o \
|
---|
91 | listsetsaction.o \
|
---|
92 | metaformat.o \
|
---|
93 | metaformatsaction.o \
|
---|
94 | oaiaction.o \
|
---|
95 | oaiargs.o \
|
---|
96 | oaiconfig.o \
|
---|
97 | oaidispatcher.o \
|
---|
98 | oaimain.o \
|
---|
99 | oaitools.o \
|
---|
100 | recordaction.o \
|
---|
101 | resumptiontoken.o \
|
---|
102 | rfc1807.o
|
---|
103 |
|
---|
104 | GSDL_LIBS = \
|
---|
105 | $(PROTOCOL_DIR)/gsdlprotocol.a \
|
---|
106 | $(COLSERVR_DIR)/gsdlcolservr.a \
|
---|
107 | $(INDEXERS_DIR)/mg/src/text/libmgtext.a \
|
---|
108 | $(INDEXERS_DIR)/mg/lib/libmglib.a \
|
---|
109 | $(INDEXERS_DIR)/mgpp/text/libmgpptext.a \
|
---|
110 | $(INDEXERS_DIR)/mgpp/lib/libmgpplib.a \
|
---|
111 | $(GSDL_DIR)/lib/gsdllib.a
|
---|
112 |
|
---|
113 | EXECUTABLE_OBJECTS = \
|
---|
114 | $(OBJECTS) \
|
---|
115 | $(RECPT_OBJECTS) \
|
---|
116 | $(GSDL_LIBS)
|
---|
117 |
|
---|
118 | EXECUTABLE = oaiserver
|
---|
119 |
|
---|
120 |
|
---|
121 | oaiserver: $(EXECUTABLE_OBJECTS)
|
---|
122 | $(CPPLINK) $(EXECUTABLE_OBJECTS) $(LIBS)
|
---|
123 |
|
---|
124 | all: $(EXECUTABLE)
|
---|
125 |
|
---|
126 | install: $(EXECUTABLE)
|
---|
127 | $(INSTALL) -m 755 -s $(EXECUTABLE) $(GSDL_DIR)/cgi-bin
|
---|
128 |
|
---|
129 | clean:
|
---|
130 | rm -f $(OBJECTS) $(EXECUTABLE)
|
---|
131 |
|
---|
132 | distclean:
|
---|
133 | rm -f $(OBJECTS) $(EXECUTABLE) Makefile
|
---|
134 |
|
---|
135 | depend:
|
---|
136 | makedepend -Y -- $(DEFS) $(INCLUDES) $(CPPFLAGS) -- $(SOURCES)
|
---|