source: main/trunk/greenstone2/runtime-src/src/corba/Makefile.in@ 21324

Last change on this file since 21324 was 21324, checked in by ak19, 14 years ago

Changes to makefiles, configure files, and source code to work with the new configure flags that allow indexers to be individually compiled up by setting each indexer to be enabled or disabled (enable-mg, enable-mgpp, enable-lucene)

File size: 4.4 KB
Line 
1###########################################################################
2#
3# Makefile -- runtime-src/src/corba
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 = ../../..
28COMMON_DIR = $(GSDL_DIR)/common-src
29RUNTIME_DIR = $(GSDL_DIR)/runtime-src
30
31INDEXERS_DIR = $(COMMON_DIR)/indexers
32COMMON_PACKAGES_DIR = $(COMMON_DIR)/packages
33RUNTIME_PACKAGES_DIR = $(RUNTIME_DIR)/packages
34COLSERVR_DIR = $(RUNTIME_DIR)/src/colservr
35PROTOCOL_DIR = $(RUNTIME_DIR)/src/protocol
36RECPT_DIR = $(RUNTIME_DIR)/src/recpt
37
38
39ENABLE_ACCENTFOLD = @ENABLE_ACCENTFOLD@
40ifeq ($(ENABLE_ACCENTFOLD), 1)
41ACCENTFOLD_LIBS = $(INDEXERS_DIR)/packages/unac/libunac.a
42else
43ACCENTFOLD_LIBS =
44endif
45
46
47ENABLE_MG = @ENABLE_MG@
48ifeq ($(ENABLE_MG), 1)
49MG_INDEXERS_LIBS = $(INDEXERS_DIR)/mg/src/text/libmgtext.a \
50 $(INDEXERS_DIR)/mg/lib/libmglib.a
51else
52MG_INDEXERS_LIBS =
53endif
54
55ENABLE_MGPP = @ENABLE_MGPP@
56ifeq ($(ENABLE_MGPP), 1)
57MGPP_INDEXERS_LIBS = $(INDEXERS_DIR)/mgpp/text/libmgpptext.a \
58 $(INDEXERS_DIR)/mgpp/lib/libmgpplib.a
59MGPP_INCLUDES = -I$(INDEXERS_DIR)/mgpp/text
60else
61MGPP_INDEXERS_LIBS =
62MGPP_INCLUDES =
63endif
64
65
66USE_SQLITE = @USE_SQLITE@
67ifeq ($(USE_SQLITE), 1)
68SQLITE_LIBS = $(COMMON_PACKAGES_DIR)/sqlite/lib/libsqlite3.a -ldl -lpthread
69else
70SQLITE_LIBS =
71endif
72
73MICO_DIR = @MICO_DIR@
74MICO_VER = @MICO_VER@
75ifeq ($(MICO_DIR), default)
76MICO_INCLUDES = -I$(RUNTIME_PACKAGES_DIR)/mico/mico/include
77MICO_PATH = $(RUNTIME_PACKAGES_DIR)/mico/bin/
78else
79ifeq ($(MICO_DIR), yes)
80MICO_INCLUDES =
81else
82MICO_INCLUDES = -I$(MICO_DIR)
83endif
84MICO_PATH =
85endif
86
87USE_CORBA = @USE_CORBA@
88ifeq ($(USE_CORBA), 1)
89AR = ar
90CC = @CC@
91CFLAGS = @CFLAGS@
92DEFS = @DEFS@ -DNZDL -DQUIET -DSHORT_SUFFIX -DPARADOCNUM -DGSDLSERVER
93INCLUDES = -I$(COMMON_DIR)/src/lib -I$(COLSERVR_DIR) -I$(PROTOCOL_DIR) -I$(RECPT_DIR) $(MGPP_INCLUDES) \
94 $(MICO_INCLUDES)
95INSTALL = @INSTALL@
96LDFLAGS = @LDFLAGS@
97LIBS = @LIBS@ $(COMMON_PACKAGES_DIR)/gdbm/lib/libgdbm.a -L$(COMMON_PACKAGES_DIR)/expat/lib -lexpat \
98 $(ACCENTFOLD_LIBS) $(SQLITE_LIBS) -L$(RUNTIME_PACKAGES_DIR)/mico/lib -lmico$(MICO_VER)
99RANLIB = @RANLIB@
100
101
102COMPILE = $(MICO_PATH)mico-c++ -x c++ $(CFLAGS) $(DEFS) $(INCLUDES) -c
103LINK = $(MICO_PATH)mico-ld $(LDFLAGS) -o $@
104
105
106.SUFFIXES: .mpp .o
107.mpp.o:
108 $(COMPILE) $<
109
110
111SOURCES = \
112 corbaconv_text_t.mpp \
113 corbaiface.mpp \
114 corbaiface_skel.mpp \
115 corbaproto.mpp \
116 corbatext_t.mpp
117
118OBJECTS = \
119 corbaconv_text_t.o \
120 corbaiface.o \
121 corbaiface_skel.o \
122 corbaproto.o \
123 corbatext_t.o
124
125CORBASERVER_OBJECTS = \
126 corbaServer.o
127
128CORBARECPT_OBJECTS = \
129 corbaclient.o
130
131GSDL_LIBS = \
132 $(RECPT_DIR)/gsdlrecpt.a \
133 $(PROTOCOL_DIR)/gsdlprotocol.a \
134 $(COLSERVR_DIR)/gsdlcolservr.a \
135 $(MG_INDEXERS_LIBS) \
136 $(MGPP_INDEXERS_LIBS) \
137 $(COMMON_DIR)/src/lib/gsdllib.a
138
139CORBASERVER_EXECUTABLE_OBJECTS = \
140 $(OBJECTS) \
141 $(CORBASERVER_OBJECTS) \
142 $(GSDL_LIBS)
143
144CORBARECPT_EXECUTABLE_OBJECTS = \
145 $(OBJECTS) \
146 $(CORBARECPT_OBJECTS) \
147 $(GSDL_LIBS)
148
149EXECUTABLES = corbaserver corbarecptldd
150
151
152# Default target: make both corbaserver and corbarecptldd
153all: $(EXECUTABLES)
154
155corbaserver: $(CORBASERVER_EXECUTABLE_OBJECTS)
156 $(LINK) $(CORBASERVER_EXECUTABLE_OBJECTS) $(LIBS)
157
158corbarecptldd: $(CORBARECPT_EXECUTABLE_OBJECTS)
159 $(LINK) $(CORBARECPT_EXECUTABLE_OBJECTS) $(LIBS)
160
161depend:
162 makedepend -Y -- $(DEFS) $(INCLUDES) $(CXXFLAGS) -- $(SOURCES)
163
164install:
165
166clean:
167 rm -f $(OBJECTS) $(CORBASERVER_OBJECTS) $(CORBARECPT_OBJECTS) $(EXECUTABLES)
168
169else
170all:
171depend:
172install:
173clean:
174endif
175
176# Want to do distclean regardless of whether or not been compiled
177# distclean needs to get rid of anything produced by ./configure such
178# as this makefile!
179
180
181distclean: clean
182 rm -f Makefile
183
Note: See TracBrowser for help on using the repository browser.