source: main/trunk/greenstone2/runtime-src/packages/security/gs-code-changes/configure_scripts/runtime-src/packages_unfinished/Makefile.in@ 28886

Last change on this file since 28886 was 28886, checked in by ak19, 10 years ago

Additions to the OWASP-for-C++ security package, even though we are no longer using this now. Adding Dr Bainbridge's new files esapitools.cpp and .h, in case we use this in future, along with its Makefile.in. Adding configure files to enable/disable the security package. (The Makefile in runtime-src/packages is not yet complete.)

File size: 6.4 KB
Line 
1###########################################################################
2#
3# Makefile -- Makefile for packages included with Greenstone runtime
4#
5# A component of the Greenstone digital library software
6# from the New Zealand Digital Library Project at the
7# University of Waikato, New Zealand.
8#
9# Copyright (C) 2000 New Zealand Digital Library Project
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
28USE_Z3950=@USE_Z3950@
29USE_YAZ=@USE_YAZ@
30USE_APACHE_HTTPD=@USE_APACHE_HTTPD@
31
32USE_SECURITY=@USE_SECURITY@
33#ifeq ($(USE_SECURITY), 1)
34#else
35#SECURITY=
36#endif
37
38
39ifeq ($(USE_Z3950), 1)
40# make sure USE_YAZ is set
41USE_YAZ=1
42D2M=d2m
43else
44D2M=
45endif
46
47ifeq ($(USE_YAZ), 1)
48# we only compile the src and client dirs for now.
49YAZ=yaz/yaz-2.1.4/src yaz/yaz-2.1.4/client
50else
51YAZ=
52endif
53
54
55USE_CORBA=@USE_CORBA@
56MICO_DIR=@MICO_DIR@
57ifeq ($(USE_CORBA), 1)
58ifeq ($(MICO_DIR), default)
59CORBA="mico/mico"
60else
61CORBA=
62endif
63else
64CORBA=
65endif
66
67GSDLOS = @gsdlos@
68
69ifeq ($(USE_APACHE_HTTPD), 1)
70HTTPD=apache-httpd/httpd-2.2.11
71else
72HTTPD=
73endif
74
75
76# PACKAGEDIRS contains the packages that we want to make and install. It
77# is assumed that each package will have at least four rules: all, install,
78# clean, and distclean.
79INSTALLDIRS = $(YAZ) $(D2M) $(CORBA) $(SECURITY)
80PACKAGEDIRS = $(INSTALLDIRS) $(HTTPD)
81
82REPLACELIST = conf/extra/httpd-dav.conf \
83 conf/extra/httpd-manual.conf \
84 conf/extra/httpd-autoindex.conf \
85 conf/extra/httpd-vhosts.conf \
86 conf/extra/httpd-ssl.conf \
87 conf/extra/httpd-multilang-errordoc.conf \
88 conf/original/extra/httpd-dav.conf \
89 conf/original/extra/httpd-manual.conf \
90 conf/original/extra/httpd-autoindex.conf \
91 conf/original/extra/httpd-vhosts.conf \
92 conf/original/extra/httpd-ssl.conf \
93 conf/original/extra/httpd-multilang-errordoc.conf \
94 conf/original/httpd.conf\
95 lib/apr-util-1/apr_dbd_odbc.la \
96 lib/apr-util-1/apr_dbd_sqlite3.la \
97 lib/pkgconfig/apr-util-1.pc \
98 lib/pkgconfig/apr-1.pc \
99 lib/libaprutil-1.la \
100 lib/libapr-1.la \
101 build/config_vars.mk \
102 build/config.nice \
103 build/apr_rules.mk \
104 bin/dbmmanage \
105 bin/apu-1-config \
106 bin/apr-1-config \
107 include/ap_config_auto.h \
108 include/ap_config_layout.h
109
110all:
111 for odir in $(PACKAGEDIRS); do \
112 echo making $@ in $$odir; \
113 (cd $$odir && $(MAKE) $(MDEFINES) $@) || exit 1; \
114 done
115ifeq ($(USE_APACHE_HTTPD), 1)
116# Need to make install here, otherwise src/recpt won't be able
117# to compile mod_gsdl.cpp with installed header files etc.
118 (cd $(HTTPD) && $(MAKE) $(MDEFINES) install) || exit
119endif
120
121ifeq ($(CORBA), "mico/mico")
122 cd mico/mico; $(MAKE) $(MDEFINES) install
123 mkdir -p ../bin/linux
124 mkdir -p ../lib
125 mkdir -p ../include
126 mkdir -p ../man
127 cp -f mico/bin/* ../bin/linux
128 cp -f mico/lib/* ../lib/
129 cp -fr mico/include/* ../include
130 cp -fr mico/man ../man
131endif
132ifeq ($(USE_YAZ), 1)
133# need to do make install in include and src dirs to get the header files and
134# lib file into the right place
135 cd yaz/yaz-2.1.4/include; $(MAKE) $(MDEFINES) install
136 cd yaz/yaz-2.1.4/src; $(MAKE) $(MDEFINES) install
137endif
138
139# make install all packages in the security folder
140
141
142# now install everything except apache, since that had already been installed during "all"
143install:
144 for idir in $(INSTALLDIRS); do \
145 echo installing $$idir; \
146 (cd $$idir && $(MAKE) install) || exit 1; \
147 done
148ifeq ($(USE_APACHE_HTTPD), 1)
149 mkdir -p ../../apache-httpd/$(GSDLOS)/conf
150 cp -f apache-httpd/httpd.conf.in ../../apache-httpd/$(GSDLOS)/conf/.
151 mkdir -p ../../etc/logs-gsi
152 @ echo "*************** INFO ***************"
153 @ echo "Run: source setup.bash, to set up the environment for greenstone"
154 @ echo "Type: make configure-admin, to set the admin password"
155 @ echo "Edit: llssite.cfg files to change the port number if necessary"
156 @ echo "Type: make configure-web, to configure the included apache webserver"
157 @ echo "EITHER type: make web-start, to launch the webserver from the command-line"
158 @ echo "OR run: gs2-server.sh, to launch the GUI version of the included webserver"
159 @ echo "************************************"
160endif
161
162clean:
163 for subdir in $(PACKAGEDIRS); do \
164 echo cleaning $@ in $$subdir; \
165 (cd $$subdir && $(MAKE) clean || exit 0) ; \
166 done
167
168distclean:
169 rm -f Makefile
170 for subdir in $(PACKAGEDIRS); do \
171 echo cleaning $@ in $$subdir; \
172 (cd $$subdir && $(MAKE) distclean || exit 0) ; \
173 done
174
175apache-for-dist:
176 ( httpddir=`cd ./apache-httpd/httpd* ; pwd` ; \
177 cp $$httpddir/support/apxs.in ../../apache-httpd/$(GSDLOS)/apxs.in ; \
178 cp apache-httpd/install-bindist.sh ../../apache-httpd/$(GSDLOS)/install-bindist.sh ; \
179 chmod 755 ../../apache-httpd/$(GSDLOS)/install-bindist.sh ; \
180 gsdldir=`cd ../.. ; pwd` ; \
181 pre="$$gsdldir/apache-httpd/$(GSDLOS)" ; \
182 for one_file in apachectl envvars envvars-std; do \
183 sed -e "s%$$pre%*\*\APACHE_HOME_OS\*\*%" "$$pre/bin/$$one_file" > "$$pre/bin/$$one_file.in" ; \
184 cp "$$pre/bin/$$one_file.in" "$$pre/bin/$$one_file" ; \
185 done ; \
186 for one_file in $(REPLACELIST); do \
187 sed -e "s%$$pre%*\*\APACHE_HOME_OS\*\*%" "$$pre/$$one_file" > "$$pre/$$one_file.in" ; \
188 cp "$$pre/$$one_file.in" "$$pre/$$one_file" ; \
189 done ; \
190 cat "$$pre/bin/apr-1-config" \
191 | sed -e "s%^APR_SOURCE_DIR=.*%APR_SOURCE_DIR=%" \
192 | sed -e "s%^APR_BUILD_DIR=.*%APR_BUILD_DIR=%" \
193 > "$$pre/bin/apr-1-config.in" ; \
194 cp "$$pre/bin/apr-1-config.in" "$$pre/bin/apr-1-config" ; \
195 cat "$$pre/bin/apu-1-config" \
196 | sed -e "s%^APU_SOURCE_DIR=.*%APU_SOURCE_DIR=%" \
197 | sed -e "s%^APU_BUILD_DIR=.*%APU_BUILD_DIR=%" \
198 > "$$pre/bin/apu-1-config.in" ; \
199 cp "$$pre/bin/apu-1-config.in" "$$pre/bin/apu-1-config" ; \
200 sed -e "s%^EXTRA_INCLUDES\s*=.*%EXTRA_INCLUDES=%" "$$pre/build/config_vars.mk" > "$$pre/build/config_vars.mk.in" ; \
201 cp "$$pre/build/config_vars.mk.in" "$$pre/build/config_vars.mk" ; )
Note: See TracBrowser for help on using the repository browser.