# # Copyright (C) 1996,1997 Michael R. Elkins # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. # SHELL=/bin/sh VERSION=@VERSION@ prefix=@prefix@ exec_prefix=@exec_prefix@ bindir=@bindir@ libdir=@libdir@ mandir=@mandir@ sharedir=@sharedir@ srcdir=@srcdir@ docdir=@docdir@ VPATH=@srcdir@ @SET_MAKE@ INSTALL=@INSTALL@ CC=@CC@ XCPPFLAGS=-I. @CPPFLAGS@ -DSHAREDIR=\"$(sharedir)\" -DDOTLOCK=\"$(bindir)/mutt.dotlock\" CFLAGS=@CFLAGS@ $(XCPPFLAGS) LDFLAGS=@LDFLAGS@ LIBS=@LIBS@ OPS=@OPS@ OBJS= addrbook.o alias.o attach.o browser.o buffy.o color.o \ commands.o complete.o compose.o copy.o curs_lib.o curs_main.o date.o \ edit.o enter.o flags.o init.o filter.o from.o getdomain.o \ handler.o hash.o hdrline.o headers.o help.o \ history.o hook.o keymap.o lib.o \ main.o mbox.o menu.o mh.o mx.o pager.o parse.o pattern.o \ postpone.o query.o recvattach.o rfc822.o \ rfc1524.o rfc2047.o score.o send.o sendlib.o signal.o sort.o \ status.o system.o thread.o charset.o @LIBOBJS@ CLEANFILES=dotlock mutt *.o core VERYCLEANFILES=$(CLEANFILES) Makefile config.cache config.log \ config.status config.h Muttrc DISTCLEANFILES=$(VERYCLEANFILES) tags keymap_defs.h *.rej *.orig *~ Makefile.bak # kill these files when making new export distributions NONEXPORT=pgp.c pgp.h pgpinvoke.c pgpkey.c pgppubring.c sha.h sha1dgst.c \ gnupgparse.c sha_locl.h OPS.PGP doc/pgp-Notes.txt doc/language.txt \ doc/language50.txt all: mutt @DOTLOCK_TARGET@ mutt: keymap_defs.h $(OBJS) $(REGEX) $(CC) -o mutt $(OBJS) $(REGEX) $(LDFLAGS) $(LIBS) dotlock: dotlock.o @SNPRINTFOBJS@ $(CC) -o dotlock dotlock.o @SNPRINTFOBJS@ keymap_defs.h: Makefile $(OPS) rm -f keymap_defs.h $(srcdir)/gen_defs $(OPS) > keymap_defs.h install: mutt install.doc @DOTLOCK_INSTALL_TARGET@ $(srcdir)/mkinstalldirs $(bindir) -mv -f $(bindir)/mutt $(bindir)/mutt.old $(INSTALL) -m 755 mutt $(bindir) -if [ ! -f $(sharedir)/Muttrc ]; then \ $(srcdir)/mkinstalldirs $(sharedir); \ $(INSTALL) -m 644 $(srcdir)/Muttrc $(sharedir); \ fi -if [ ! -f $(sharedir)/mime.types ]; then \ $(INSTALL) -m 644 $(srcdir)/mime.types $(sharedir); \ fi ( cd $(srcdir)/charsets && make install ) install.dotlock: dotlock $(srcdir)/mkinstalldirs $(bindir) -mv -f $(bindir)/mutt.dotlock $(bindir)/mutt.dotlock.old $(INSTALL) @DOTLOCK_GROUP@ -m @DOTLOCK_PERMISSION@ dotlock $(bindir)/mutt.dotlock install.doc: ( cd $(srcdir)/doc && $(MAKE) install ) uninstall: uninstall.doc rm -f $(bindir)/mutt $(sharedir)/Muttrc $(bindir)/mutt.dotlock uninstall.doc: ( cd $(srcdir)/doc/ && $(MAKE) uninstall ) $(srcdir)/configure: $(srcdir)/configure.in autoconf Makefile: $(srcdir)/Makefile.in ./config.status config.h.in: $(srcdir)/acconfig.h autoheader config.h: $(srcdir)/config.h.in ./config.status tags: (cd $(srcdir) && ctags *.[ch]) dep: Makefile mv Makefile Makefile.bak awk -f $(srcdir)/depend.awk < Makefile.bak > Makefile echo '# DO NOT REMOVE THIS LINE' >> Makefile $(CC) -MM $(XCPPFLAGS) $(srcdir)/*.c >> Makefile clean-real: (cd $(srcdir) && rm -f $(CLEANFILES)) (cd $(srcdir)/doc && $(MAKE) $@) clean: rm -f $(CLEANFILES) (cd $(srcdir)/charsets && $(MAKE) $@) veryclean: rm -f $(VERYCLEANFILES) distclean: (cd $(srcdir) && rm -f $(DISTCLEANFILES)) (cd $(srcdir)/doc && $(MAKE) $@) (cd $(srcdir)/charsets && $(MAKE) $@) reldate: rm -f $(srcdir)/reldate.h echo 'const char *ReleaseDate = "'`date +%Y-%m-%d`'";' > $(srcdir)/reldate.h # make export version usdist: distclean reldate rm -rf /tmp/mutt-$(VERSION) (cd .. && cp -r mutt-$(VERSION) /tmp) for i in `grep _PGPPATH $(srcdir)/*.[ch] | sed 's/^\([^:]*\).*/\1/' | grep -v '/main\.c' | grep -v '/pgp'` ; do \ target=`basename $$i` ; \ $(srcdir)/reap.pl _PGPPATH < $(srcdir)/$$target > /tmp/mutt-$(VERSION)/$$target; \ done for i in $(NONEXPORT); do \ rm -f /tmp/mutt-$(VERSION)/$$i; \ done (cd /tmp && tar cvf mutt-$(VERSION).tar mutt-$(VERSION) && gzip mutt-$(VERSION).tar) rm -rf /tmp/mutt-$(VERSION) # make international distribution dist: distclean reldate (cd $(srcdir)/.. && tar cfz mutt-$(VERSION)i.tar.gz mutt-$(VERSION)i) rx/librx.a: (cd rx && $(MAKE) CC="$(CC)" CFLAGS="$(CFLAGS)")