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

Last change on this file since 30878 was 30878, checked in by ak19, 8 years ago

Modifications to get GS2 compiling to work again on Macs after the recent ElCapitan changes around libiconv for a GS3 release.

File size: 5.8 KB
RevLine 
[15549]1###########################################################################
2#
[18226]3# Makefile -- runtime-src/src/corba
[15549]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###########################################################################
[15548]26
[18026]27GSDL_DIR = ../../..
28COMMON_DIR = $(GSDL_DIR)/common-src
29RUNTIME_DIR = $(GSDL_DIR)/runtime-src
[15548]30
[30878]31GSDLOS = @gsdlos@
32GSLDARCH = @gsdlarch@
33
[18026]34INDEXERS_DIR = $(COMMON_DIR)/indexers
35COMMON_PACKAGES_DIR = $(COMMON_DIR)/packages
[18226]36RUNTIME_PACKAGES_DIR = $(RUNTIME_DIR)/packages
[18026]37COLSERVR_DIR = $(RUNTIME_DIR)/src/colservr
38PROTOCOL_DIR = $(RUNTIME_DIR)/src/protocol
39RECPT_DIR = $(RUNTIME_DIR)/src/recpt
[15548]40
[18026]41
[15576]42ENABLE_ACCENTFOLD = @ENABLE_ACCENTFOLD@
43ifeq ($(ENABLE_ACCENTFOLD), 1)
[30878]44ifeq ($(GSDLOS),darwin)
45ACCENTFOLD_LIBS = $(INDEXERS_DIR)/packages/unac/libunac.a -liconv
46else
[25231]47ACCENTFOLD_LIBS = $(INDEXERS_DIR)/packages/unac/libunac.a $(COMMON_PACKAGES_DIR)/iconv/lib/libiconv.a
[30878]48endif
[15576]49else
50ACCENTFOLD_LIBS =
51endif
52
[21324]53
54ENABLE_MG = @ENABLE_MG@
55ifeq ($(ENABLE_MG), 1)
56MG_INDEXERS_LIBS = $(INDEXERS_DIR)/mg/src/text/libmgtext.a \
57 $(INDEXERS_DIR)/mg/lib/libmglib.a
[25231]58MG_INCLUDES = -I$(INDEXERS_DIR)/mg/lib
[21324]59else
60MG_INDEXERS_LIBS =
[25231]61MG_INCLUDES =
[21324]62endif
63
64ENABLE_MGPP = @ENABLE_MGPP@
65ifeq ($(ENABLE_MGPP), 1)
66MGPP_INDEXERS_LIBS = $(INDEXERS_DIR)/mgpp/text/libmgpptext.a \
67 $(INDEXERS_DIR)/mgpp/lib/libmgpplib.a
[25231]68MGPP_INCLUDES = -I$(INDEXERS_DIR)/mgpp/text -I$(INDEXERS_DIR)/mgpp/lib
[21324]69else
70MGPP_INDEXERS_LIBS =
71MGPP_INCLUDES =
72endif
73
[22058]74USE_GDBM = @USE_GDBM@
75ifeq ($(USE_GDBM), 1)
76GDBM_DEFINES = -DUSE_GDBM
77else
78GDBM_DEFINES =
79endif
[21324]80
[22058]81USE_JDBM = @USE_JDBM@
82ifeq ($(USE_JDBM), 1)
83JDBM_DEFINES = -DUSE_JDBM
84else
85JDBM_DEFINES =
86endif
87
[15833]88USE_SQLITE = @USE_SQLITE@
89ifeq ($(USE_SQLITE), 1)
[18026]90SQLITE_LIBS = $(COMMON_PACKAGES_DIR)/sqlite/lib/libsqlite3.a -ldl -lpthread
[22058]91SQLITE_DEFINES = -DUSE_SQLITE
[15833]92else
93SQLITE_LIBS =
[22058]94SQLITE_DEFINES =
[15833]95endif
96
[15463]97MICO_DIR = @MICO_DIR@
[15576]98MICO_VER = @MICO_VER@
[15463]99ifeq ($(MICO_DIR), default)
[25231]100MICO_INCLUDES = -I. -I$(RUNTIME_PACKAGES_DIR)/mico/mico/include
[18226]101MICO_PATH = $(RUNTIME_PACKAGES_DIR)/mico/bin/
[15463]102else
[25231]103MICO_INCLUDES = -I. -I$(MICO_DIR)
[15463]104MICO_PATH =
105endif
106
[15578]107USE_CORBA = @USE_CORBA@
108ifeq ($(USE_CORBA), 1)
[15563]109AR = ar
110CC = @CC@
[25231]111CFLAGS = -I. @CFLAGS@
112CXXFLAGS = -I. @CXXFLAGS@
[22058]113DEFS = @DEFS@ -DNZDL -DQUIET -DSHORT_SUFFIX -DPARADOCNUM -DGSDLSERVER $(GDBM_DEFINES) $(JDBM_DEFINES) $(SQLITE_DEFINES)
[25231]114INCLUDES = -I$(COMMON_DIR)/src/lib -I$(COLSERVR_DIR) -I$(PROTOCOL_DIR) -I$(RECPT_DIR) $(MG_INCLUDES) $(MGPP_INCLUDES) \
[15578]115 $(MICO_INCLUDES)
[15563]116INSTALL = @INSTALL@
117LDFLAGS = @LDFLAGS@
[18226]118LIBS = @LIBS@ $(COMMON_PACKAGES_DIR)/gdbm/lib/libgdbm.a -L$(COMMON_PACKAGES_DIR)/expat/lib -lexpat \
119 $(ACCENTFOLD_LIBS) $(SQLITE_LIBS) -L$(RUNTIME_PACKAGES_DIR)/mico/lib -lmico$(MICO_VER)
[15563]120RANLIB = @RANLIB@
[15463]121
122
[15563]123COMPILE = $(MICO_PATH)mico-c++ -x c++ $(CFLAGS) $(DEFS) $(INCLUDES) -c
[15576]124LINK = $(MICO_PATH)mico-ld $(LDFLAGS) -o $@
[15463]125
126
[15459]127.SUFFIXES: .mpp .o
128.mpp.o:
[15563]129 $(COMPILE) $<
[15459]130
131
[15563]132SOURCES = \
133 corbaconv_text_t.mpp \
134 corbaiface.mpp \
[15576]135 corbaproto.mpp \
[15563]136 corbatext_t.mpp
[25231]137# corbaiface_skel.mpp \
[15471]138
[15563]139OBJECTS = \
140 corbaconv_text_t.o \
141 corbaiface.o \
[15576]142 corbaproto.o \
[15563]143 corbatext_t.o
[25231]144# corbaiface_skel.o \
[15471]145
[15578]146CORBASERVER_OBJECTS = \
147 corbaServer.o
148
149CORBARECPT_OBJECTS = \
150 corbaclient.o
151
[15576]152GSDL_LIBS = \
[15578]153 $(RECPT_DIR)/gsdlrecpt.a \
[15576]154 $(PROTOCOL_DIR)/gsdlprotocol.a \
155 $(COLSERVR_DIR)/gsdlcolservr.a \
[21324]156 $(MG_INDEXERS_LIBS) \
157 $(MGPP_INDEXERS_LIBS) \
[18233]158 $(COMMON_DIR)/src/lib/gsdllib.a
[15471]159
[15578]160CORBASERVER_EXECUTABLE_OBJECTS = \
[15576]161 $(OBJECTS) \
[15578]162 $(CORBASERVER_OBJECTS) \
[15576]163 $(GSDL_LIBS)
164
[15578]165CORBARECPT_EXECUTABLE_OBJECTS = \
166 $(OBJECTS) \
167 $(CORBARECPT_OBJECTS) \
168 $(GSDL_LIBS)
[15576]169
[15578]170EXECUTABLES = corbaserver corbarecptldd
[15576]171
[15471]172
[15578]173# Default target: make both corbaserver and corbarecptldd
174all: $(EXECUTABLES)
[15472]175
[15578]176corbaserver: $(CORBASERVER_EXECUTABLE_OBJECTS)
177 $(LINK) $(CORBASERVER_EXECUTABLE_OBJECTS) $(LIBS)
[15472]178
[15578]179corbarecptldd: $(CORBARECPT_EXECUTABLE_OBJECTS)
180 $(LINK) $(CORBARECPT_EXECUTABLE_OBJECTS) $(LIBS)
[15471]181
[16586]182depend:
183 makedepend -Y -- $(DEFS) $(INCLUDES) $(CXXFLAGS) -- $(SOURCES)
184
[15578]185install:
[25231]186# We're in a linux makefile, so we know what the GSDLOS is if this
187# Makefile is run:
188 cp corbaserver ../../../cgi-bin/linux/.
189 if test -e corbarecptldd; then cp corbarecptldd ../../../cgi-bin/linux/.; fi
[15471]190
[15578]191clean:
192 rm -f $(OBJECTS) $(CORBASERVER_OBJECTS) $(CORBARECPT_OBJECTS) $(EXECUTABLES)
[15471]193
[15549]194else
195all:
[16586]196depend:
[15549]197install:
198clean:
[15548]199endif
[16586]200
[25231]201corbaiface.h corbaiface.mpp: corbaiface.idl
202
203# Because sequential commands are independent (each line seems to be run in its own shell),
204# need to set the path env vars and run the IDL command in the same cmd, so it remembers
205# the env vars when running the idl executable
206# (NOTE: In the past, before BOA changed to POA in corba code, skeleton files were
207# required. If needed again, generate them with the --c++-skel option to idl.)
208 export PATH=$(RUNTIME_PACKAGES_DIR)/mico/bin:${PATH};export LD_LIBRARY_PATH=$(RUNTIME_PACKAGES_DIR)/mico/lib:${LD_LIBRARY_PATH};idl --c++-suffix mpp corbaiface.idl;
209
[16586]210# Want to do distclean regardless of whether or not been compiled
211# distclean needs to get rid of anything produced by ./configure such
212# as this makefile!
213
214
215distclean: clean
216 rm -f Makefile
217
Note: See TracBrowser for help on using the repository browser.