[559] | 1 | ###########################################################################
|
---|
| 2 | #
|
---|
| 3 | # Makefile -- gsdl
|
---|
| 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 |
|
---|
[552] | 27 | PACKAGE = @PACKAGE@
|
---|
| 28 | VERSION = @VERSION@
|
---|
| 29 |
|
---|
| 30 | @SET_MAKE@
|
---|
| 31 | CC = @CC@
|
---|
| 32 | CPP = @CXX@
|
---|
| 33 | CFLAGS = @CFLAGS@
|
---|
| 34 | LIBS = @LIBS@
|
---|
[555] | 35 | MDEFINES =
|
---|
| 36 | TOPSRC = `pwd`
|
---|
[552] | 37 |
|
---|
[704] | 38 | GSDLOS = @gsdlos@
|
---|
| 39 |
|
---|
[552] | 40 | COMPILE = $(CC) -c
|
---|
| 41 |
|
---|
[555] | 42 | SOURCES =
|
---|
[552] | 43 |
|
---|
[555] | 44 | OBJECTS =
|
---|
[552] | 45 |
|
---|
| 46 | ALLFILES = $(OBJECTS)
|
---|
| 47 |
|
---|
[704] | 48 | INSTALLDIRS = packages/mg src/recpt src/txt2db src/db2txt src/hashfile
|
---|
[552] | 49 |
|
---|
[704] | 50 | OTHERDIRS = packages/mg lib src/colservr src/recpt src/txt2db src/db2txt src/hashfile
|
---|
[559] | 51 |
|
---|
[552] | 52 | all:
|
---|
[555] | 53 | sed s^XXXX^$(TOPSRC)^ lib/gsdlhome.h.example > lib/gsdlhome.h
|
---|
[704] | 54 | mkdir -p bin/$(GSDLOS)
|
---|
[559] | 55 |
|
---|
| 56 | for odir in $(OTHERDIRS); do \
|
---|
| 57 | echo making $@ in $$odir; \
|
---|
| 58 | (cd $$odir && $(MAKE) $(MDEFINES) $@) || exit 1; \
|
---|
[552] | 59 | done
|
---|
| 60 |
|
---|
[704] | 61 | install:
|
---|
| 62 |
|
---|
[559] | 63 | for idir in $(INSTALLDIRS); do \
|
---|
| 64 | echo installing $$idir; \
|
---|
| 65 | (cd $$idir && $(MAKE) install) || exit 1; \
|
---|
| 66 | done
|
---|
| 67 |
|
---|
[555] | 68 | clean:
|
---|
[691] | 69 | rm -f Makefile config.cache config.h config.log stamp-h
|
---|
[555] | 70 | rm lib/gsdlhome.h
|
---|
[559] | 71 | for subdir in $(INSTALLDIRS) $(OTHERDIRS); do \
|
---|
[555] | 72 | echo cleaning $@ in $$subdir; \
|
---|
| 73 | (cd $$subdir && $(MAKE) clean) || exit 1; \
|
---|
| 74 | done
|
---|
| 75 |
|
---|
[691] | 76 | # For an explanation of the following Makefile rules, see node
|
---|
| 77 | # `Automatic Remaking' in GNU Autoconf documentation.
|
---|
| 78 | Makefile: Makefile.in config.status
|
---|
| 79 | CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status
|
---|
| 80 | config.status: configure
|
---|
| 81 | ./config.status --recheck
|
---|
| 82 | configure: configure.in aclocal.m4
|
---|
| 83 | cd $(srcdir) && autoconf
|
---|
[555] | 84 |
|
---|
[691] | 85 | config.h: stamp-h
|
---|
| 86 | stamp-h: config.h.in config.status
|
---|
| 87 | CONFIG_FILES= CONFIG_HEADERS=config.h ./config.status
|
---|
| 88 | config.h.in: stamp-h.in
|
---|
| 89 | stamp-h.in: configure.in aclocal.m4 acconfig.h
|
---|
| 90 | cd $(srcdir) && autoheader
|
---|
| 91 | $(TOUCH) $(srcdir)/stamp-h.in
|
---|
[555] | 92 |
|
---|
[691] | 93 |
|
---|
| 94 |
|
---|