SHELL=		/bin/sh
TOPDIR=		..
PZCONFIG=	$(TOPDIR)/zmailer.Config
INSTALL=	@INSTALL@
MAILBIN=	$(prefix)@MAILBIN@

srcdir=         @srcdir@
VPATH=          @srcdir@

BINS=	autoanswer.pl policy-builder.sh \
	$(srcdir)/make-incore.sh $(srcdir)/bitbucket

all:
	cd makedb ; $(MAKE) $(MFLAGS)
	cd vacation ; $(MAKE) $(MFLAGS)

install:
	cd makedb ; $(MAKE) $(MFLAGS) install
	cd vacation ; $(MAKE) $(MFLAGS) install
	for BIN in $(BINS); do \
		if [ ! -f $$BIN ] ; then \
			$(INSTALL) -m 755 $$BIN  $(MAILBIN) ; \
		fi ; \
	done
	$(INSTALL) -m 755 $(srcdir)/bitbucket $(MAILBIN)/ta

FRC:


clean:	FRC
	rm -f ./+* *~
	cd vacation ; $(MAKE) $(MFLAGS) clean
	cd makedb ; $(MAKE) $(MFLAGS) clean

distclean: clean
	rm -f Makefile autoanswer.pl policy-builder.sh zmailer.init.sh
	cd vacation ; $(MAKE) $(MFLAGS) distclean
	cd makedb ; $(MAKE) $(MFLAGS) distclean

depend:
