[3745] | 1 | # Main Makefile for GNU tar.
|
---|
| 2 | # Copyright (C) 1994, 1995 Free Software Foundation, Inc.
|
---|
| 3 |
|
---|
| 4 | # This program is free software; you can redistribute it and/or modify
|
---|
| 5 | # it under the terms of the GNU General Public License as published by
|
---|
| 6 | # the Free Software Foundation; either version 2, or (at your option)
|
---|
| 7 | # any later version.
|
---|
| 8 |
|
---|
| 9 | # This program is distributed in the hope that it will be useful,
|
---|
| 10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 12 | # GNU General Public License for more details.
|
---|
| 13 |
|
---|
| 14 | # You should have received a copy of the GNU General Public License
|
---|
| 15 | # along with this program; if not, write to the Free Software
|
---|
| 16 | # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
---|
| 17 |
|
---|
| 18 | PACKAGE = @PACKAGE@
|
---|
| 19 | VERSION = @VERSION@
|
---|
| 20 |
|
---|
| 21 | @SET_MAKE@
|
---|
| 22 | SHELL = /bin/sh
|
---|
| 23 | VPATH = @srcdir@
|
---|
| 24 | exec_prefix = @exec_prefix@
|
---|
| 25 | prefix = @prefix@
|
---|
| 26 | srcdir = @srcdir@
|
---|
| 27 |
|
---|
| 28 |
|
---|
| 29 | CC = @CC@
|
---|
[10921] | 30 | CFLAGS = @CFLAGS@ -fpic
|
---|
[3745] | 31 | INSTALL = @INSTALL@
|
---|
| 32 | INSTALL_DATA = @INSTALL_DATA@
|
---|
| 33 | INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
---|
| 34 | LDFLAGS = @LDFLAGS@
|
---|
| 35 | LIBS = @LIBS@
|
---|
| 36 | TOUCH = echo timestamp >
|
---|
| 37 |
|
---|
| 38 | bindir = $(exec_prefix)/bin
|
---|
| 39 | infodir = $(prefix)/info
|
---|
| 40 | libexecdir = $(exec_prefix)/libexec
|
---|
| 41 |
|
---|
| 42 | MDEFINES =
|
---|
| 43 | #CC='$(CC)' CFLAGS='$(CFLAGS)' LDFLAGS='$(LDFLAGS)' LIBS='$(LIBS)' \
|
---|
| 44 | #prefix='$(prefix)' exec_prefix='$(exec_prefix)' \
|
---|
| 45 | #bindir='$(bindir)' libexecdir='$(libexecdir)' \
|
---|
| 46 | #infodir='$(infodir)' infodir='$(infodir)' libexecdir='$(libexecdir)'
|
---|
| 47 |
|
---|
[3757] | 48 | SUBDIRS = lib src/text src/images src/scripts java/org/greenstone/mg jni
|
---|
[3745] | 49 |
|
---|
| 50 | .SUFFIXES:
|
---|
| 51 |
|
---|
| 52 | all install uninstall execinstall execuninstall maninstall manuninstall: config.h
|
---|
| 53 | for subdir in $(SUBDIRS); do \
|
---|
| 54 | echo making $@ in $$subdir; \
|
---|
| 55 | (cd $$subdir && $(MAKE) $(MDEFINES) $@) || exit 1; \
|
---|
| 56 | done
|
---|
| 57 |
|
---|
| 58 | # Have not written any texinfo files for the documentation yet
|
---|
| 59 | #info dvi:
|
---|
| 60 | # cd doc && $(MAKE) $@
|
---|
| 61 |
|
---|
| 62 | check: all
|
---|
| 63 | echo making $@ in ./test directory
|
---|
| 64 | (cd ./test && $(MAKE) all) || exit 1
|
---|
| 65 | ./test/testmg `pwd`
|
---|
| 66 |
|
---|
| 67 | mostlyclean: mostlyclean-recursive mostlyclean-local
|
---|
| 68 |
|
---|
| 69 | clean: clean-recursive clean-local
|
---|
| 70 |
|
---|
[7732] | 71 | distclean: distclean-recursive distclean-local
|
---|
[3745] | 72 |
|
---|
| 73 | maintainer-clean: maintainer-clean-recursive maintainer-clean-local
|
---|
| 74 | rm -f config.status
|
---|
| 75 |
|
---|
[7732] | 76 | mostlyclean-recursive clean-recursive distclean-recursive maintainer-clean-recursive:
|
---|
[3745] | 77 | for subdir in $(SUBDIRS); do \
|
---|
| 78 | target=`echo $@ | sed 's/-recursive//'`; \
|
---|
| 79 | echo making $$target in $$subdir; \
|
---|
| 80 | (cd $$subdir && $(MAKE) $$target) || exit 1; \
|
---|
| 81 | done
|
---|
| 82 |
|
---|
| 83 | mostlyclean-local:
|
---|
| 84 |
|
---|
| 85 | clean-local: mostlyclean-local
|
---|
| 86 |
|
---|
| 87 | distclean-local: clean-local
|
---|
[7732] | 88 | rm -f Makefile stamp-h config.status config.h config.log
|
---|
[3745] | 89 |
|
---|
| 90 | maintainer-clean-local: distclean-local
|
---|
| 91 | @echo "This command is intended only for maintainers to use;"
|
---|
| 92 | @echo "rebuilding the deleted files may require special tools."
|
---|
| 93 |
|
---|
| 94 | # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
---|
| 95 |
|
---|
| 96 | distdir = $(PACKAGE)-$(VERSION)
|
---|
| 97 |
|
---|
| 98 | distname = $(distdir)
|
---|
| 99 |
|
---|
| 100 | DISTFILES = \
|
---|
| 101 | INSTALL.mg INSTALL README README.port COPYING MODIFICATIONS about_mg.html \
|
---|
| 102 | Makefile.in acconfig.h aclocal.m4 configure.in install-sh mkinstalldirs \
|
---|
| 103 | config.guess config.sub \
|
---|
| 104 | config.h.in configure stamp-h.in sysfuncs.h
|
---|
| 105 |
|
---|
| 106 | dist: $(DISTFILES)
|
---|
| 107 | #-----------------------------------------------------------------
|
---|
| 108 | #create distribution directory
|
---|
| 109 | -rm -rf $(distdir)
|
---|
| 110 | mkdir $(distdir)
|
---|
| 111 | #
|
---|
| 112 | #link in local distribution files
|
---|
| 113 | ln $(DISTFILES) $(distdir)
|
---|
| 114 | #
|
---|
| 115 | #link in SampleData
|
---|
| 116 | mkdir $(distdir)/SampleData
|
---|
| 117 | (cd SampleData; $(MAKE) "distdir=../$(distdir)/SampleData" dist)
|
---|
| 118 | # link in davinci stuff
|
---|
| 119 | mkdir $(distdir)/SampleData/davinci
|
---|
| 120 | (cd SampleData/davinci; \
|
---|
| 121 | $(MAKE) "distdir=../../$(distdir)/SampleData/davinci" dist)
|
---|
| 122 | # link in bible stuff
|
---|
| 123 | mkdir $(distdir)/SampleData/bible
|
---|
| 124 | (cd SampleData/bible; \
|
---|
| 125 | $(MAKE) "distdir=../../$(distdir)/SampleData/bible" dist)
|
---|
| 126 | #
|
---|
| 127 | #link in tests
|
---|
| 128 | mkdir $(distdir)/test
|
---|
| 129 | (cd test; $(MAKE) "distdir=../$(distdir)/test" dist)
|
---|
| 130 | #
|
---|
| 131 | #link in docs directory
|
---|
| 132 | mkdir $(distdir)/docs
|
---|
| 133 | (cd docs; $(MAKE) "distdir=../$(distdir)/docs" dist)
|
---|
| 134 | #
|
---|
| 135 | #link in lib directory
|
---|
| 136 | mkdir $(distdir)/lib
|
---|
| 137 | (cd lib; $(MAKE) "distdir=../$(distdir)/lib" dist)
|
---|
| 138 | #
|
---|
| 139 | #link in src distribution files
|
---|
| 140 | mkdir $(distdir)/src
|
---|
| 141 | for dir in src/text src/images src/scripts; do \
|
---|
| 142 | echo makeing $@ in $$dir ; \
|
---|
| 143 | mkdir $(distdir)/$$dir; \
|
---|
| 144 | (cd $$dir; $(MAKE) "distdir=../../$(distdir)/$$dir" $@) ; \
|
---|
| 145 | done
|
---|
| 146 | #
|
---|
| 147 | # archive and compress
|
---|
| 148 | tar -chf - $(distdir) | gzip -9 > $(distname).tar.gz
|
---|
| 149 | tar -chf - $(distdir) | compress > $(distname).tar.Z
|
---|
| 150 | #
|
---|
| 151 | # cleanup
|
---|
| 152 | rm -rf $(distdir)
|
---|
| 153 | #-----------------------------------------------------------------
|
---|
| 154 |
|
---|
| 155 | # Tell versions [3.59,3.63) of GNU make not to export all variables.
|
---|
| 156 | # Otherwise a system limit (for SysV at least) may be exceeded.
|
---|
| 157 | .NOEXPORT:
|
---|